Democrats have often criticised Trump for being negative and failing to provide hope. I wanted to test this by doing sentiment analysis on Trumps tweets since being elected. Then comparing that to his pre-election tweets. As always the code I used is in my code blog, here.
Analysis of Trump's pre election tweets total positive tweets = 196 (12%) total neutral tweets = 1330 (79%) total negative tweets = 150 (9%) More than 3 out of 4 are neutral. And the majority of the non neutral tweets are positive. Analysis of Trumps' post election tweets total positive tweets = 95 (34%) total neutral tweets = 135 (48%) total negative tweets = 49 (18%) So almost half are neutral, one in 3 are positive and less than one in five are negative. The sample size for post election tweets is smaller but both data sets are in some agreement - the majority of tweets are neutral and positive tweets out-number negative tweets. In the code blog I explain the technical aspects of this analysis and some of the potential weaknesses in the approach. In a future post I will describe an alternative approach using machine learning. In conclusion I don't agree with commentators who claim Trump's message is mostly negative at least not on his twitter account. If anything his message has a neutral sentiment. However I think this approach to sentiment analysis is a little simplistic becuase it fails to consider the individual words in the context of the whole tweet.
0 Comments
Leave a Reply. |