with natural language processing
Suppose you are launching an exciting new meme…
meme ranked third best on Reddit
Your only source of feedback is thousands of comments.
How do you turn this into workable data?
| “This is hilarious!” |
| “Made me laugh out loud” |
| “Not bad” |
| “Meh” |
| “I don’t get it” |
| … |
| “Could be better” |
Natural language processing enables the vectorization of arbitrary text.
| “This is hilarious!” | Good |
| “Made me laugh out loud” | Good |
| “Not bad” | Neutral |
| “Meh” | Bad |
| “I don’t get it” | Bad |
| … | |
| “Could be better” | Neutral |
Now you do not need to read every comment to know how your meme is performing!
| “This is hilarious!” | Good | 0.90 |
| “Made me laugh out loud” | Good | 0.50 |
| “Not bad” | Neutral | 0.21 |
| “Meh” | Bad | -0.65 |
| “I don’t get it” | Bad | -0.55 |
| … | ||
| “Could be better” | Neutral | -0.17 |
What does this mean for me?
Now, you can convert qualitative data to quantitative data!
At its core, sentiment analysis uses large dictionaries of words and their weights.
| “excellent” | 1.0 |
| “awful” | -1.0 |
\[ Sentiment(T) = \sum_{i=1}^{T_{length}}weight(T_i) \]
Why is this useful?
You can use sentiment analysis to understand nearly any idea, not just positive or negative.
How is this useful?
SentimentAnalysis is very easy to use.
library(SentimentAnalysis)
texts <- c("I love this meme!", "This is okay.", "Not funny at all.")
analyzeSentiment(texts)
This code produces a sentiment value for all three statements.
Learn more about sentiment analysis at
https://cran.r-project.org/web/packages/SentimentAnalysis/
Noah Christensen
noah_christensen1@baylor.edu