Monday, 16 April 2012

The 9th London Mayoral Election Twitter Poll


Click on pictures to enlarge

Poll findings
1) Well big changes today at least in how the poll is constructed. I wanted to put some kind of limit on the number of tweets that anyone tweeter could tweet that would be included in the analysis. I was going to keep secret to flummox anyone wanting to bias it. However during the course of coding I was able to find a solution that resulted in using tweeters that only mention a candidate only once. Go selecting data using logical conditions. Anyway I will see how this goes. Today it doesn't seemed to have changed from the normal pattern but obviously to volume reached has been lower.

2)Boris got more mentions but he was pretty much even with Ken on sentiment. So basically it's a toss up but slightly leaning to Boris.

3)Looking at the YouGov poll released today you've got a picture which show the big 2 out front and the others in something of a scrum at the bottom. I couldn't see a margin of error on there but expect with would have been something around +/- 3% so Paddick on 7% may feel better than Jones on 2% but Jones's +3% = 5% which is higher than Paddick's -3%  which = 4%.. I will do proper calculations to work out the correlation between my data and the result but at the moment it's not looking too bad even if the BorKen lead over the rest is understated.

4) Carlos has put in an appearance today. Suspect he got in the media somehow the tweets were mainly laughing at him. So we are getting near the prospect of a BNP mayor deporting himself.

5) Siobhan wins the Mary Poppins ward for highest positive rating & lowest negative. Though her figures aren't looking THAT different from the others. Jenny Jones shouldn't allow some American to use her name for chatshow reasons or at least get them to air the series after the election.


Results

    Candidate Pos9 Neut9 Neg9 Tot9 Pospercent9 Negpercent9
1    BorisCON  243   447  185  875          28          21
2      KenLAB  168   256  120  544          31          22
3 BrianLIBDEM   46   127   62  235          20          26
4  JennyGREEN   49    74   78  201          24          39
5  SiobhanIND  127   152   69  348          36          20
6   CarlosBNP    7    30   15   52          13          29

Sunday, 15 April 2012

The 8th London Mayoral Election Twitter Poll



Poll findings
1) Well what a poll! As you can see there are two volume polls out today and no sentiment ones as yet. This is because I got a shock when I first did the poll as Siobhan Benita came out top in volume! Yes I know Boris and Ken's volumes are both down probably because it's the weekend but still it would have been the shock of the Twitter polling season. However on closer examination of the data it became clear that the total had been somewhat inflated by one tweeter so I'm introducing a limit to the tweets I count from each tweeter starting now.

I have applied it above with the adjusted graph so her volume figure falls from 756 to 483. I have checked the tweets of the the other candidates as well and no one else appears to be doing anything else similar. I don't think it was a deliberate attempt to skew the poll because it would have been the most rubbish attempt ever. 

2) In other news Ken's negatives have fallen below Boris's for the first time. This isn't going to totally undo the damage of recent times for Ken but it's an indication that the story is moving on.

3) Even with the adjustment Benita still got a higher volume than Ken for the first time today.

4)Brian and Jenny steady as they go I think.

5) UKIP and the BNP fail to make the cut. AGAIN.



Results

The adjusted figures


    Candidate Pos8 Neut8 Neg8 Tot8 
1       Ken Lab   95   232  125  452                   
2     Boris Con  158   266  224  648                   
3   Jenny Green   51    69   55  175           
4 Brian Lib Dem   61   111   67  239                  
5   Siobhan Ind                  483 


How does the poll work 

Tweets are collected from Twitter and then counted to give the volume figures and then they are classified by the sentiment package which is an addition to the R programming language I use for this. They're classified based on the content of the tweet. So something like "Love @mayoroflondon he's brilliant" would end up in the positive pile while "I'm going to rip Boris Johnson's ugly evil head off if no bus in 30secs" would end up in the negative pile. If it's not quite to obvious then there's the neutral category.

Progress so far....

 Click to enlarge.

In response to public demand he's a chart of the volume of tweets each candidate has got over the last week I've been getting data. I also be doing the positive and negative sentiment figures at some point as well.

Obviously the Lib Dems wouldn't admit it but they can't be happy being bottom for 5 of the last 7 days. Given that one of the other day's was Paddick's manifesto launch  Neither will the Greens be happy to be beneth Benita every day. Then comes the key question both for this experiment and the election how much do tweets translate into votes or at least registering on proper opinion polls with correctly weighted samples?

There does appear to be something of a pattern emerging with the top 2 somewhat correllated and the bottom 3 similarly bound together. We'll see if that continues next week.

My methodology does favour the smaller parties so I suspect Ken and Boris are quite a bit further ahead in reality but I get twitter handles and full names rather than first names so this shrinks the gap between the politicians on first name terms with the electorate as oppossed to those who aren't even famous in their own household. This is for two reasons 1) capacity the API I use searches for a max of 1500 tweets per search term if I search for Ken instead of Ken Livingstone then I would be much more likely to reach full capacity and miss tweets. 2) There are quite a few other Ken and Boris's in the world so if it's full names I'm searching for at least I know I'm getting the right ones.

The other two candidates didn't feature on the graph as it was hard enough doing it with data where they weren't any gaps.

R\ggplot2\data stuff

This was something of a pig to do but a good learning excercise nontheless. Things to note for the future. The date has to be the correct date format. Whatever you do don't spend hours faffing about making things into factors or as.integers or as.characters or any of that gubbins. You want as.Date.

Need to work out how to select the colours.

Data need to be in the sort of format you see below


Candidate Date Volume
Boris 08/04/12 489
Ken 08/04/12 569
Siobhan 08/04/12 333
Jenny 08/04/12 303
Brian 08/04/12 164
Boris 09/04/12 1541
Ken 09/04/12 839
Siobhan 09/04/12 271
Jenny 09/04/12 183

Saturday, 14 April 2012

The 7th London Mayoral Election Twitter Poll


Poll findings
1) Has peace and harmony broken out on the London front? Not quite but Ken, Jenny, Brian and Siobhan all have better percentage figures for both positive and negative today. Boris is 2% better off on his negative but 4% down on his positive so not a big change there.

2) Volume of tweets was down alot especially Boris and Ken but Siobhan's also fell a little. Suspect it's because it's a Saturday but Jenny's and Brian's volume increased. I would put this down to hustings today I think there was one organised by Stonewall and another Youth one. So that means less time for Boris and Ken to get on the telly hence their figures go down. Jenny and Brian get equal billing and hence see increases in their total. Well that's my theory anyway.

3) Ken has had a difficult week on the trail but is he starting to turn the corner? Yesterday the gap between Boris and Ken's negative percentage was 18% ie 39 vs 21 today it's 25 vs 18. If and it's a big if this improvement continues there starts to be a realistic argument to move the race back from leans Boris to toss-up between the two.

4) There's going to be a Yougov poll on the London Mayoral race on Monday that'll be a big day for the Benita campaign. If she fails to register again like ComRes than it's going to look like a campaign in a social media bubble with little resonance on the ground. But it'll be worth looking at the question as the ComRes one disadvantaged the smaller campaigns by not mentioning their candidate name in the question. Today she's won the Mary Poppins award for the highest positive rating and the lowest negative one as well.

5) UKIP an the BNP failed to make the cut. AGAIN. So clearly not putting the effort in.

How does the poll work 

Tweets are collected from Twitter and then counted to give the volume figures and then they are classified by the sentiment package which is an addition to the R programming language I use for this. They're classified based on the content of the tweet. So something like "Love @mayoroflondon he's brilliant" would end up in the positive pile while "I'm going to rip Boris Johnson's ugly evil head off if no bus in 30secs" would end up in the negative pile. If it's not quite to obvious then there's the neutral category.


Results


      Candidate Pos7 Neut7 Neg7 Tot7 Negpercent7 Pospercent7
1       Ken Lab  309   539  276 1124          25          27
2     Boris Con  202   349  129  680          19          30
3   Jenny Green  165   321   92  578          16          29
4 Brian Lib Dem  123   206   64  393          16          31
5   Siobhan Ind  224   297   81  602          13          37

Friday, 13 April 2012

The 6th London Mayoral Twitter Poll


Poll findings:
1) Another day on the campaign trail gone and Boris will be doing most of the smiling tonight. Not only did he get a bounce from banning the gay cure bus adverts his main rivals negatives are sticking out like a sore thumb. Again.

2) If I was to explain this apparent voter preference for Boris over Ken. I would say this. There are people on the left who hate Boris and the're people on the right who hate Ken but what I think the results are showing is that there is something of a likeability gap between Ken and Boris amongst people who aren't interested in politics. This is a problem for Ken. I suggest a cute puppy accompany him everywhere.

3)  Another good result for Siobhan Benita 3rd again in volume. Her negatives seemed to have joined the normal political race but she's still the most benignly viewed candidate on Twitter. I think my methodology does favour her a little bit at least compared to the ComRes poll question that didn't mention her. Where's she going to end up? I think the comedy candidate choice by the BNP is going to put them last. If your supporters are anti immigrant giving them an immigrant to vote for unless I'm missing something here isn't going to get them out to vote in vast numbers. Then I think you've got a band going from one of the candidates having a bad election on 3% to about 10% at the other end. In this scrum go UKIP, Greens, Lib Dems and Benita. Who comes out top? Who comes out bottom? Difficult to say but if she can keep bring home these impressive Twitter stats the chances of getting nearer the top of that band have got to increase.


4)
Jenny stayed much the same as yesterday but Brian seems to have dropped down a plughole in volume terms. Some way 5th can't be a comfortable place for Mr Paddick to storm to victory from


5) A rare appearence for Lawrence Webb of UKIP in the Twitter poll he had quite a few mentions of him going on various radio progammes and assorted media appearence and these were mostly classified as neutral. Sample size is really to small to read anything into it.





      Candidate Pos6 Neut6 Neg6 Tot6 Negpercent6 Pospercent6
1       Ken Lab  423  1043  930 2396          39          18
2     Boris Con  690   893  429 2012          21          34
3   Jenny Green   72   230   88  390          23          18
4 Brian Lib Dem   32   109   45  186          24          17
5   Siobhan Ind  239   413  176  828          21          29
6 Lawrence UKIP    0    52    4   56           7           0

Black Britain Decides on Boris

Click to enlarge the picture

Last night was the Black Britain Decides Mayoral Hustings put on by "a coalition of Black leaders including Church leaders, business leaders, activists, faith groups". It used the hashtag #blackbritaindecides. I wanted to assess the audience reaction to Boris. So I scraped all the tweets that mentioned #blackbritaindecides and Boris there were 474. So there was certainly reaction to him. As you can see above it was mainly negative. Indeed this is the highest negative reaction on any of the polls I've done.

One of the things that hold Boris back in the election is his relationship with London's Black community. I don't think it's ever been that great. That won't have been helped by only mentioning Blacks in the crime section of his new manifesto. This is an error on Boris's part. If he could bring at least a decent chunk of Black votes over to his side he'd walk the election.

#blackbritaindecides Boris Sentiment Figures

  Sentiment Percent
1  Positive      11
2   Neutral      31
3  Negative      57

Adds up to 99% due to rounding.

Thursday, 12 April 2012

The 5th London Mayoral Twitter Poll

Poll findings

1) Ken top of the negatives, bottom of the positives today. Ok his negatives are lower than yesterday and his positives are higher but still Boris is probably happier with his results than Ken is with his own. Overall I would say it's still all to play for but I'd delve into the lexicon of the American political tipster and say London is a district that is slightly leaning towards Boris at the moment at least on Twitter. Ken will have been cheered up with Labour's performance in the East Finchley local by election and if the grannies of London who are unrepresented on this new medium take umbridge at the granny tax then Boris could come a cropper but I think Boris has opened up a bridgeable clink of light between the pair of them. 

2) Siobhan Benita top of the positives, bottom of the negatives. Ken would kill for her ratings but her volume is down and has dropped behind the Lib Dems which is never to great accolade for anyone in politics at the moment.


3) Brian Paddick may have the second highest negative ratings after Ken but at least the 2nd time "celebrity" candidate has got more volume than someone who chucked her job in a short while ago.

4) Boris got a mention from virtually Royalty herself @Queen_UK today and on Russell Howard's good news. Quite a few people declared their love for Boris Johnson as he's funny. Humour and love that's a powerful combination.


5) Have decided UKIP and BNP must think Twitter is a foreign invader and must be repelled by not being mentioned on it if at all possible. Given the low bar they have to cross to be featured (20 proper tweets) they or their supporters if they have any clearly aren't putting in the effort.


      Candidate Pos5 Neut5 Neg5 Tot5 Negpercent5 Pospercent5
1       Ken Lab  418  1018  726 2162          34          19
2     Boris Con  707   853  521 2081          25          34
3   Jenny Green   78   213   92  383          24          20
4 Brian Lib Dem  189   284  203  675          30          28
5   Siobhan Ind  202   292   82  576          14          35