Voter Sentiment
Carles Llacer Sep 15, 2012 14:35 PM

Wow, that looks complicated. How do you calculate the score? Do natural language processing libraries come with tools to analyze the sentiments, or you just look for positive and negative words??

Scott Bartell Sep 15, 2012 17:41 PM

Currently I am not using any libraries for the sentiment analysis. Basically, I make sure that each tweet I look at only mentions a single candidate (to ensure that the words within the tweet are only about that candidate). Then I run the tweet through a list of positive and negative words. Every positive word gets +1 and every negative word gets -1 for the respective candidate. After 10 minutes of this a final score is calculated and plotted on the graph.

CrowdEndowed Sep 21, 2012 03:05 AM

Now, this is really cool! Do you intend to provide statistics for periods longer than 10 min? It would be really cool to see historic data for last day, month, year, defined period, major events (during rnc and dnc.) If you integrated with an ai package (I have a recommendation, if youâ€™re interested) in few years, you could make some real predictions about the outcome of the elections. :)

Anthony Pace Sep 29, 2012 16:57 PM

Hello Scott great work. Btw how would you handle a phrases like 'Obama is the f***ing man', or 'if you don't vote for obama you're a stupid idiot.'? From the looks of things, those would be considered negative sentiment too right? Do you intend to refine it to work with phrases later?

Scott Bartell Oct 02, 2012 01:14 AM

Hello Anthony, thanks for the comment! I'm working on an implementation that will work to address this issue. I came up with the idea to look at the individual words within a tweet and determine the probability that a tweet will be negative, positive, or neutral (such as news) based on the presence of particular words. I'm gathering data and writing/testing an algorithm right now. Surprisingly, even with a rather small sample size, the algorithm seems to be rather accurate.

David S Oct 31, 2012 19:37 PM

There is a video on youtube called "The Structured Search Engine" by google that mentions sentiment analysis and sounds like they might even have a paper on it that could help with some of the problems that Anthony mentioned

Anthony Udacity Nov 28, 2012 19:37 PM

Just curious. How did the project actually hold up during the election?

Scott Bartell Nov 28, 2012 20:46 PM

The completely transparent answer is.. everything blew up. I have been aware of the problem since the first presidential debate - when the volume of tweets reaches a "tipping point", my server cannot keep up with Twitter's stream anymore and eventually Twitter's API disconnects the me. I have a few ideas for a solution but unfortunately I haven't been able to make any changes because I've been very busy working on a startup :) On a side note: I have also been considering making voter sentiment open source and will do so if I receive enough requests.

Developers
Scott Bartell
Description

A real time analysis of Twitter sentiment towards the 2012 U.S. Presidential candidates: Barack Obama and Mitt Romney.

Voter Sentiment looks at a live stream of relevant tweets for 10 minutes, determines the general sentiment towards each candidate over those 10 minutes and outputs a Sentiment Rating.

Voter Sentiment also generates a word cloud which displays the most frequently tweeted words for each Sentiment Rating. Users are also able to see the overall frequency a specific word has been used in tweets about a specific candidate.