Create an impressionist self-portrait from your Twitter followers

April 11, 2014

(This article was first published on Revolutions, and kindly contributed to R-bloggers)

Here's something fun you can do with R and its interface to Twitter, the TwitteR package. An R script by CMU student Mark Patterson downloads your Twitter profile picture, counts the number of Twitter followers you have, and then creates a pointillist version of your profile picture with as many dots as you have followers. Here's mine:


Note that to use Mark's script you will need to install the BioConductor package EBImage (follow the instructions in yellow on that page) and create a Twitter app and authenticate it. Once you've got those set up, call general.func("yourTwitterHandle") to create your own!

Decisions and R: Visualizing Twitter Followers Using Pointillism

To leave a comment for the author, please follow the link and comment on his blog: Revolutions. offers daily e-mail updates about R news and tutorials on topics such as: visualization (ggplot2, Boxplots, maps, animation), programming (RStudio, Sweave, LaTeX, SQL, Eclipse, git, hadoop, Web Scraping) statistics (regression, PCA, time series, trading) and more...

If you got this far, why not subscribe for updates from the site? Choose your flavor: e-mail, twitter, RSS, or facebook...

Comments are closed.