Category Archives: Twitter

The (Local) General Election on Twitter

The UK’s national election is decided on a constituency basis: 650 odd separate small elections, each returning one MP. Despite the obvious importance of national parties and their leaders for shaping the election campaign as a whole, it is commonly accepted that the ability of local campaigns is also a significant factor. For example, the Liberal Democrats are well known for having highly organised local activities in their home constituencies; something which might help them hold onto seats despite their overall poor polling in national polls. Given this, for those interested in the influence of social media on the election, it’s worth looking not just at nationally relevant hashtags and Twitter accounts, but how local candidates have been using social media.

In a previous post Taha Yasseri and Stefano de Sabbata looked at the distribution of candidate accounts on Twitter, based on data from YourNextMP. In this post, using the same YNMP data as well as tweets collected by Scott Hale from the Twitter Streaming API over the last month, we look at the actual tweeting activity of MPs. The map below shows the level of activity of each MP in each British constituency for six UK parties in the month leading up to the election. The scale shows light, medium and heavy users of Twitter

OII - GE2015 - Candidate Activity on Twitter - Bright, Hale - web

Level of candidate activity on Twitter

Almost 450,000 tweets were sent by candidates of these six parties in the month leading up to the general election (the Labour party sent over 120,000, the Conservatives and the Green Party sent around 80,000 each, the Liberal Democrats just over 70,000, UKIP just over 60,000 and the SNP just over 15,000).

Compared to the map which Taha and Stefano produced on account distribution, in this new one regional patterns are clearly more apparent: whereas the major parties have candidates with Twitter accounts almost uniformly across the UK, their level of usage varies a lot. Only the SNP are uniform heavy users of Twitter: only two of their candidates sent less than 10 tweets in this period, and the majority sent more than 100. This also chimes with the fact that they are the party who has, relative to the overall number of candidates, created the most Twitter accounts – clearly they have a very active and organised social media presence.

OII - GE2015 - Tweet Histograms - Bright, Hale

Candidate activity on Twitter by party

The histogram above show more detail about the level of twitter activity and how it breaks down between different parties. Conservative, Green and Labour have broadly similar patterns, with the average candidate having sent around 100 tweets in the last month, whilst a few have sent several thousand. UKIP and the Liberal Democrats show a flatter distribution.

Of course, it’s one thing to tweet, but is anyone else actually listening? More on that soon…

Which parties are having the most impact on Twitter?

The previous two posts have shown that the amount of effort parties are putting in on Twitter at the local level is pretty variable. But what about the response they are getting? In this post we’ll look at the amount of mentions candidates receive on Twitter. A mention could be a retweet or it could be a message @ someone – any time the candidate’s name is in there. Data was harvested from Datasift, using the same YourNextMP data for the list of candidate Twitter handles.

In the week before the election candidates were mentioned over one million times. Lots of that activity, it goes without saying, goes to the party leaders: Ed Miliband accounts for almost 120,000 of those mentions alone, with, Cameron, Farage, Clegg and Bennett in places 2 – 5. Yet there was also a lot of activity for less nationally famous figures: over the 2,312 candidates in the YourNextMP dataset, only 12 weren’t mentioned even once during that week (and none of them tweeted either).

Why do some candidates get more attention than others? The most obvious explanation is that some candidates tweet more than others: and being active on social media ought to be a way of getting noticed. The image below plots all of the candidates in the dataset as a point, comparing the number of times they tweeted with the number of times they are mentioned, on a logarithmic scale. The positive relationship is clear.


Twitter mentions of local party candidates

However within all the points, there also seem to be some differences between the parties.  The figure below makes the different clearer by grouping all the candidates into a per party average. What it shows is that, while for every party writing more tweets tends to get more mentions, some parties have a much better “Tweet to mention” ratio than others. In other words, their tweets have on average more impact, and their presence is on average greater. Like the previous one, this graph is on a log scale, meaning that the differences between parties are in orders of magnitude. So, for example, 100 tweets from a Lib Dem candidate would give around 100 mentions; but the same amount from an SNP candidate would give over 1,000 mentions.


Twitter mentions of local party candidates – averaged by party

Broadly speaking, we can see the parties form three groups on social media in terms of outreach: the SNP are clearly in front, Labour and Conservatives are in the middle, and the Greens and Liberal Democrats at the back. UKIP are somewhere in between the middle and back groups. Interestingly, these relationships hold more or less regardless of the amount of tweets sent by the candidate (and the most famous candidates were by no means the most avid tweeters – Miliband for example only authored 20 tweets in this period, whilst others authored several hundred).

Summary? Some parties have a lot more impact on social media than others.

NB: Post was updated slightly @ 19.45 to correct a data collection issue – overall conclusions weren’t change.

What if mentions were votes?

The last post looked at mention activity for each British constituency. What would happen if we took these mentions to be votes? Does this reaction from social media offer any potential insight into what might happen in the election? In the image below (top),  using the same week of Twitter data from Datasift and YourNextMP, we identify which party “won” the Twitter mention battle in each constituency. The blank constituency on the map is Buckingham (the speaker’s constituency), and we have of course excluded Northern Ireland and Plaid Cymru entirely, which was done purely to limit the number of parties and hence make the job a bit more feasible in real time.

Of course, as we highlight in the previous post, there is a strong relationship between the amount of times a candidate tweeted and the amount of mentions they got: and we don’t want to just measure how much effort candidates have been putting in online, but the relative level of attention they generate. Hence in the map we divide the overall number of mentions of a candidate by the amount of tweets they published themselves, giving us a kind of relative measure of a candidate’s impact on Twitter.

The map below ours is a constituency level forecast based on polling data for the purposes of comparison, lifted straight from our colleagues at


Constituency level Twitter winners

Constituency level prediction from

As you can see the number of seats “won” in the Twitter vote diverges significantly from the model (which is, of course, much closer to what is actually going to happen), but is nevertheless not entirely unrealistic. Labour are understated to a large degree, whilst the reverse is true for UKIP and the Green Party. Labour, Liberal Democrats and SNP are somewhere within the ball park (+/- 30).

Of course, we didn’t really expect this type of method to offer a perfect “prediction” of the election: it would be a major surprise (and probably a coincidence) if it did. My guess is it indicates more something about the loyal / activist base present in a constituency than voter levels. Hence it will be interesting to see if the seats given to some of the more minor parties using this method are areas where these parties do surprisingly well or beat the national trend. For example, are the 35 Green Party constituencies we highlight places where the Greens manage to make a major improvement on their vote share?