The following document is going to go through sentiment analysis on two brands. These two brands are Nike and Adidas and the data that is being referred to has been gathered from the Twitter API.
Anti Join gets rid of words we do not want ahd have no sentiment
nike <- rtweet_nike %>%
unnest_tokens(word, full_text)
adidas <- rtweet_adidas%>%
unnest_tokens(word, full_text)
tidy_nike <- rtweet_nike %>%
unnest_tokens(word, full_text) %>%
anti_join(stop_words)
tidy_adidas <- rtweet_adidas %>%
unnest_tokens(word,full_text) %>%
anti_join(stop_words)
I intend on collecting data regarding sentiments of these brands and see what words of controversy or negative effects have. This will help because I can see what kind of words people are using to describe these brands and thus and gather a sentiment of how these brands are treated.
As you can see there is a wider variety of words that have been used frequently to describe Nike than Adidas. However, there is also a larger amount of words that have a negative connotation that have been used. In my opinion, Nike is a larger brand, however, there is more controversy surrounding them thus leading me to think that Adidas is preferred.
I will gather tweets from the past few days stating these two brands and will use a count of the amount of tweets in order to find out which brand has been being talked about more.
In the past few days it is seen that Nike has been tweeted about more often. This is expected because Nike has more controversy surrounding them.
I will gather tweets about these brands and use the NRC Lexicon in order to compare sentiment of the brands. These sentiments will help see which brand has a better sentiment to the consumers.
Only 21% of nike tweets have positive sentiments while adidas has 33%. On the flip side, 13% of adidas sentiments are negative while only 11% of Nike’s sentiments are negative. The large gap in positive tweets leads me to believe that even though there is a larger percent of negative tweets, adidas is still more popular.
combined_sentiment <-
bind_rows(nike_sentiment,adidas_sentiment)
combined_sentiment %>%
ggplot(aes(x=sentiment, y = `Percent of scoreable words`))+
geom_col(position = "dodge") +
scale_y_continuous(labels = scales::percent) +
labs(title = "A comparison of the emotive sentiments found in Nike and Adidas",
subtitle = "Using the NRC Lexicon (Mohammad and Turney, 2013), shown as a percent of scorable words",
x = "Sentiment")
As a whole, the brands both elicit positive sentiments! Behind positivity, the brands also seem to elicit a lot of trust, anticipation, and joy, but also negativity!