Celebrating one year of blogging with a word cloud
Want to share your content on R-bloggers? click here if you have a blog, or here if you don't.
This month marks the one year anniversary of Design Data Decisions! To celebrate, I decided to do a ‘visual display’ of this blog by creating a word cloud out of articles posted thus far. Using R.
This task turned out to be very easy, because of a cool word cloud generator function that I found in http://www.sthda.com/english/wiki/word-cloud-generator-in-r-one-killer-function-to-do-everything-you-need. So I just needed to install the required R packages ("tm", "SnowballC", "wordcloud", "RColorBrewer", "RCurl", "XML")
and then call the word cloud generator function rquery.wordcloud(), supplying the blog URL as an argument, and my task was done:
source('http://www.sthda.com/upload/rquery_wordcloud.r') url <- "https://designdatadecisions.wordpress.com" res <- rquery.wordcloud(x=url, type="url", min.freq = 8, max.words = 200, excludeWords=c("using","used","use","can","also"), colorPalette="Dark2") ## exclude common words and restrict to words with frequency >= 8, just to get a better picture
with the resulting word cloud:
‘data’ is there, but I probably need to focus on ‘design’ and ‘decisions’ in my upcoming posts. Well, that in itself is a ‘decision’ 🙂
R-bloggers.com offers daily e-mail updates about R news and tutorials about learning R and many other topics. Click here if you're looking to post or find an R/data-science job.
Want to share your content on R-bloggers? click here if you have a blog, or here if you don't.