Earlier I got some help as to how to make a script that will extract hashtags from a list of tweets and put them into an array of cells.
I used this as my code, inside a for loop
hashtagCell{i} = regexp(textRead{i}, '#[A-z]*', 'match');
This works for what it is supposed to do, but now I’m trying to find the average character length of the hashtags, so I need to be able to add the character length of each hashtag pulled out by the above function and add them together. However, when I try to use the size() function, it just gives me the size of the cell instead of the size of the strings, which is what I want. I can’t figure out how to do this.
This should help (and it gets rid of any loops, other than, perhaps, the one used to create
CellOfText):DISCLAIMER: The inspiration for this method came from this excellent answer to a similar question. Thanks to @Andrey for that.