[R] Question about output from twitteR package
dluke at gwbmail.wustl.edu
Sat Jul 23 06:02:53 CEST 2011
I am trying to develop a tutorial on how to analyze network data from Twitter conversations for a network analysis class that I teach. I came across the twitteR package, and saw some examples of it in action on various websites. It is easy to use, and almost as easy to understand. I was able to pull sets of Twitter messages into a dataframe using various criteria (hashtags, etc.). To build a network, I would like to follow which messages are responses to earlier messages. According to the twitteR package documentation, this is stored in a 'replyToSN' field (reply to Screenname). However, when I do searches this field is always blank (NA). (The similar field replyToSID is also always blank.) The Twitter messages themselves suggest that there are some replies in the sets that I'm obtaining, so I now in theory that these fields should not be blank for every message.
Here is some code and output to make this clearer:
tweets = searchTwitter("#Rstats", n=200)
 "RT @kdnuggets: Great post on using parallel processing with R and HHP $3M competition http://bit.ly/rcfztQ #rstats #hhp #datamining"
tweets.df = ldply(tweets, function(t) t$toDataFrame())
replyToSN created replyToSID screenName
1 NA 2011-07-23 01:56:46 NA cmprsk
2 NA 2011-07-23 01:38:58 NA muteokie
3 NA 2011-07-23 00:27:32 NA floss4science
4 NA 2011-07-23 00:16:06 NA dichika
5 NA 2011-07-22 22:20:55 NA cmprsk
6 NA 2011-07-22 21:50:43 NA siah
I hope I'm missing something simple, but my gut tells me that I need to do some type of authentification before this information will be returned. I couldn't find any useful examples of this issue or how to get around it after looking for a while.
More information about the R-help