Social Mining using R

1. 200 tweets are extracted from hashtag “#california” and 200 from hashtag “#newyork”.
2. Then create 2 corpus from the 2 datasets.
3. Preprocess the corpus using {tm} package from R.
4. Compute and display the most frequent terms (words) in each corpus.
5. Create 2 word clouds from the most frequent terms.
6. Compute the sentiment scores, i.e. determine whether words used in the tweets are more positively or negatively charged (emotionally).

![sentimentscores.png](/site_media/media/7d5429b20e891.png)
###Sentiment scores summary:###
In general, tweets from both states have positive sentiments. However, it seem like tweets from #california appear to have a more negative connotation than #newyork.

## Facebook API ##
1. Consume 100 most recent Facebook posts by user “joebiden” using getPage() from R’s {RFacebook} package.
a. Find the most liked post and it’s popularity.
b. Find the most commented post and the number of comments.
c. Create a word cloud based on the most popular words used in the most commented post.
2. Consume 100 most recent Facebook posts containing the word “petaluma” using searchPages().
a. Rank the most frequent words and display a barplot of it.