2
Dear colleagues, I am trying to do a twittering analysis of a Timeline and needed to stemiate the texts for analysis. I am trying the following procedure:
setup_twitter_oauth(consumer_key, consumer_secret, access_token, access_secret)
tweets <- userTimeline("Pragmatismo_", n = 3000)
tweets.df <- twListToDF(tweets)
myCorpus <- Corpus(VectorSource(tweets.df$text))
removeURL <- function(x) gsub("http[[:alnum:][:punct:]]*", "", x)
removeNumPunct <- function(x) gsub('[[:punct:]]', '', x)
myCorpus <- tm_map(myCorpus, content_transformer(removeNumPunct))
myCorpus <- tm_map(myCorpus, content_transformer(removeURL))
myCorpus <- tm_map(myCorpus, ptstem)
The point is that even after the last command myCorpus <- tm_map(myCorpus, ptstem)
the text does not appear stemmed.
Any tips? Thank you very much!
Does that help you? https://github.com/dfalbel/ptstem
– Tomás Barcellos
I’ll try. Thank you!
– user135517
The function
ptstem
which is used intm_map
At first it is not defined in the question, nor in the most common libraries for that purpose. Could you indicate which package you removed it from? Or enter the function you programmed...– Guilherme Parreira