Text Mining with Bag-of-Words in R
Ted Kwartler
Instructor
# Load corpus coffee_tweets <- read.csv("coffee.csv")
# Vector of tweets coffee_tweets <- coffee_tweets$text
# View first 5 tweets head(coffee_tweets, 5)
[1] "@ayyytylerb that is so true drink lots of coffee"
[2] "RT @bryzy_brib: Senior March tmw morning at 7:25 A.M. in the SENIOR lot. Get up early, make yo coffee/breakfast, cus this will only happen ?"
[3] "If you believe in #gunsense tomorrow would be a very good day to have your coffee any place BUT @Starbucks Guns+Coffee=#nosense @MomsDemand"
[4] "My cute coffee mug. http://t.co/2udvMU6XIG"
[5] "RT @slaredo21: I wish we had Starbucks here... Cause coffee dates in the morning sound perff!"
Text Mining with Bag-of-Words in R