Ever wondered which Twitterers you and a friend share? Using R and the twitteR package, there's an easy way to find out. Cornelius Puschmann hacked together some R code to do just that for the Humanities and Technology Camp and it seems to work pretty well. Just replace 'coffee001' with the your Twitter username, 'mypassword' with your Twitter password, and 'Cornelius' with your friend's Twitter name, and the code does the rest. The only problem I had was that my graph was very cluttered, and despite the comments indicating you can set n to a smaller number, it didn't work for me. (The code is very clearly commented, by the way.) I had to add the following two lines to make a readable chart:
friends.object <- friends.object[1:25]
followers.object <- followers.object[1:25]
The chart of followers I (@revodavid) share with the RevolutionR twitter account is below.
Although to be honest, looking at the chart now, I'm not actually sure this is our shared followers. I'll have to look at the code more closely to figure out what's going on; in any case it's a neat example of integrating R with the Twitter API.
Cornelius Puschmann's Blog: Code and brief instruction for graphing Twitter with R
cool!
Posted by: Leonardo Kenji | May 28, 2010 at 04:57
Very, very cool!
Posted by: Best Twitter Apps | August 10, 2010 at 08:24
This is definitely awesome!
Posted by: Twitter Software | August 14, 2010 at 05:33
Does this work if you have tons and tons of followers or are following tons of people?
Posted by: Blogging to the Bank | August 14, 2010 at 05:34
I just recently started using the twitteR package. It seems that it can only access public data since twitter switched to OAuth. Does anyone know if there is an R package out there that can handle OAuth and allow for users to retrieve data that requires authentication?
Thanks in advance.
Posted by: Dan Bowen | November 12, 2010 at 15:12