Saturday 31 August 2013

Getting into the swing of things

After my attempt at a general formula to approximate seat-swing from marginality and national swing crashed and burnt, I started looking at the possibility of formulating a swing index. This would basically be a value for each seat. For example, a seat that generally experiences a smaller-than-average swing might have an index of 0.5, meaning in a national swing of, say, 7 percentage points that seat could be expected to have a swing of around 0.5 x 7 = 3.5 percentage points.

For this purpose, I looked at the last three federal elections (2010, 2007 and 2004) and calculated their swings from the post election pendulums (e.g. the 2004 swing is the difference between the Two-Party-prefered result in 2001 and 2004.) Note that the post-election pendulum (aka election results pendulum) is different to the pre-election pendulum for the following year, since corrections are made following by-elections, redistribution of seat boundaries etc.

The pendulums I used are as follows: 2010, 2007, 2004 and 2001. Some seats had to be excluded due to the nature of the calculations. Any seat that had elected an independent or minor party during those four years would confuse the data from the simple 2PP ALP v Coalition analysis I was conducting. That was goodbye to Calare (Independent 2001-2004), Calwell (Independent 2001), Cunningham (Greens 2004), Denison (Independent 2010), Kennedy (Independent 2001-2010), Lyne (Independent 2010), Melbourne (Greens 2010) and New England (Independent 2004-2010). Three more seats were excluded because the second party was a minor party (which would also mess with the 2PP data): Batman (ALP v Greens 2010), Grayndler (ALP v Greens 2010) and O'Connor 2010 (renegade Nationals v Liberal). Had Melbourne still been in play, it too would have been excluded after 2007's ALP v Greens. Finally, any seats that had only contested the 2010 election could not be assigned swings, so Durack, McMahon and Wright were also excluded. Other seats with short enough histories to not date back to 2001 (Bonner, founded in 2004, Flynn founded in 2007 and Gorton founded in 2004) have been included but lack some of the early data.

So, to jump right into things, here is a graph of each (usable) seat's swings from '04 to '10. (Negative swings are swings away from the incumbent.)


Now to appreciate how closely each seat reflects the national trend, we need to normalise the direction of the swings so that they are all swings to or from the same party. Or, if this were a science-fiction pollitical arena, it would be time to (selectively) reverse the pollarity. (See what I did there? POLLarity? Oh, never mind...)

Here are the same seats with there swings towards the party (or parties in tha case of 2004) that would go on to form government (Coalition 2004, ALP 2007 and 2010).


Notice that the green and blue swings are generally positive, while those from 2010 are generally negarive. This is a good sign, since the public vote swung towards the future government in '04 (Howard) and '07 (Rudd), but away from Gillard's Labor in 2010.

There is still work to do though. Some seats demonstrate large swings one year and small ones another. This is starting to look like random, but lets double check to be sure, by eliminating the variable of national swing magnitude. All swings might be expected to be exagerated in volatile years with large national swings, but quite small in the more stable campaigns.

Here is one last graph, reprisenting the swings as a proportion of the national swing, according to the formula (Seat Swing)/(National Swing) x 100%:

This was also the point at which I realised that a single tall bar graph makes more sense than chopping up a column graph.
Now almost all of the graph lies in the positive - which is unsurprising, given that if most of the seat level swings went against the national swing there would be some pretty odd outliers. That said, Wakefield's -1000% swing in 2004 is pretty nuts.

Other than that, there does not seem to be any indication of such things as big-swing and small-swing seats. Perhaps a longer view of the history will prove otherwise, ignoring some recent outlier elections. Then again, perhaps such paterns belong to a bygone age in that case.

Either way, we still do not have a reliable means of estimating the size of a swing in a given seat. I'll give it all a bit more thought, but I cannot promise any progress on this front.

Polls, polls, polls...

They’re not very useful things, but if we didn’t have polls what would we use to fill our newspapers with?

The problems with polls are legion, and have been discussed by many of the bloggers listed to the right (and many more of the 146 million Google hits for ‘the problem with polls’). Then there are the dreaded polls of polls gaining popularity in the United States, which are generally just an average of other polls. While it may seem superficially reasonable to assume that an average will iron out errors between the polls (e.g. neutralise the biases of two opposing polling houses), unfortunately not all errors can be so easily dealt with, and some are further entrenched or even exacerbated. For example, in phone polls it is generally easier to fill the over-60s quota than the under 30s. The only options are to keep phoning until you get enough under-30s to answer (in which case they may not be representative of the generally inaccessible younger generation) or else to mathematically exaggerate the under-30s results and minimise the over-60s to represent their proportion of the voting population. This is called scaling and can exaggerate statistical anomalies.

Then there is the constant reporting of 1 and 2 percentage point gains and losses, even though the margin of error on most polls is roughly 3 pp. And then we have all the informal polling, and push polling, and selective use of data. To illustrate, here is an often weekly “poll” published for most of this year. It is the Q&A audience demographic, excluding those weeks (e.g. the “religion Q&A”) where the audience demographic was measured on another scale (e.g. religious belief):

Interestingly, despite the roller-coaster ride of Gillard’s failing popularity, Rudd’s resurgence and the subsequent Coalition momentum –- all of which are known to have affected voter intentions –- the polls seem to have flat-lined. The Coalition flutters overhead between the 40 and 50% marks, with the ALP roughly 10 percentage points below. Coincidentally, 10% is roughly where the Greens have been sitting all year. It is almost as though the ABC picks its studio audience to give a roughly consistent 50-50 split between conservative (Lib/Nat) and progressive (ALP/Greens) views.


But my main gripe is simply the way polling has to be framed in order to be realistically achievable in terms of time and resources. The two main polls are preferred PM/approval-disapproval ratings type questions –- which are irrelevant because voters do not directly elect the PM -– and the one commonly phrased “if a vote were held today, who would you vote for?”

Now let’s ignore the point that the election is not being held today, and accept that these polls are a snapshot of the popular vote. The real issue is that our government is not elected by the popular vote. The country is divided into 150 seats, and you need to win just over 50% of the seats to form government. To win each seat you need just over 50% of the two-party preferred vote in that seat. In other words, it is possible to form a majority government with just over 25% of the vote. The TPP vote at that, which means you can win with an ever smaller support base if enough people vote for the “others”.

This means, conversely, that you can lose an election with almost three-quarters of the TPP vote. And, in an extreme hypothetical situation you could go from winning with 25.1% to losing with 74.9% in one term, giving you a loss of the back of an almost 50% swing in your favour.

Of course, in reality the swing lies mostly with the marginal voters who can win or lose a seat for a party, so it can be an accurate indicator. But if a 1% swing were predicted in favour of party A, the media would turn to their electoral pendulum and work out who would win the election assuming a uniform 1% swing. In other words all seat with a margin of 1% or less cross the floor, and the media counts up who has a majority.

Swings are rarely uniform, however. In the state WA election this year, I got a pretty close estimate of seats changing hands by assuming a swing of around ⅔ that reported in the polls. And then there was Albany, the most marginal seat on our pendulum for the ALP, which not only resisted the general dash to the Coalition, but actually improved its margin for the (now) opposition Labor party.

Now that ⅔ of the predicted swing was plucked out of mid-air, but my reasoning was simple – most of the campaigning (and in particular the “sand-bagging”) would be focused on the marginal seats, which would tighten up the figures there, while in the safe seats that no one cares about the polls would run away a little more and become exaggerated. This time around, we’ll be a little (emphasis on little) more scientific in our use of polling.

According to ABCNews24, Newspoll today released a new poll through News Limited, so you know this news is new. This poll is apparently (I’m going on second- and third-hand sources) predicting a 6% swing to the Coalition next weekend, as well as indicating a 5% decrease in the ALP primary vote in three marginal Victorian seats and 7% in five NSW coastal seats.
Note that the “coastal” demographic (which I have never really payed much attention to) is more volatile than the “marginal” chaps and chapettes. Again, the seats where the swings really matter are not quite as vulnerable as the nation as a whole.
But don’t take my word for this phenomena. (No, seriously, don’t. You’ll see why later.) Here is a graph based on the previous election’s data. It compares how marginal a seat is (vertical axis) with their swing towards the ALP (horizontal axis) from their 2007 position*.
I don’t think I have produced a more ambiguous graph yet. The scatter demonstrates an overall shift to the Coalition (I don’t know whether to call that a shift to the left or a shift to the Right…), but beyond that, not much. There are big swings in seats with high and low margins. Perhaps things become clearer if I ignore pro- and anti- incumbent swings and just look at an absolute swing across the board?


Nope. Not really.

To be fair. A line of best fit would probably run roughly bottom left to top right, but the correlation is very low with many distant outliers.

I had hoped to deduce a nice little line of best fit and use that to estimate the size of swings in various seats based on their margins to give a rough prediction of how many seats might fall during the election based on the latest poll. Unfortunately my hunch that marginal seats would be less influenced by swings is not borne out strongly in the data, so there goes that idea.

Instead, over the next few days, I will be looking at how strongly influenced by swings each seat has been over the last few elections to see if there is any logic in assigning seats a “swing index” instead. This index would represent whether the seat generally felt the trends more or less powerfully than the national average, or even if they tend to vote against the trend.

My gut feeling is that each seat will have a reasonably consistent number of swinging voters, and thus have a reasonably stable susceptibility to the factors driving the national swing. But then again, we’ve all just seen how reliable my gut feeling can be on these things.

*N.B. several seats have been omitted. Durack (WA), McMahon (NSW) and Wright (Qld) did not have a real swing, since they were created in 2010 (replacing Prospect (NSW),Lowe (NSW) and Kalgoorlie (WA)) and had no incumbent to swing to or from. However, I have still included the seats the new divisions were carved from, and the seats the old divisions amalgamated into, despite the obvious changes to their constituency makeup. Call me lazy – I know my mother does.

Denison (Tas) and Lyne (NSW) elected independents in 2010 while Kennedy (Qld) and New England (NSW) re-elected theirs. Since we are just looking at the 2PP swing, these can cause all kinds of confusion and misunderstanding. That does not mean these seats’ data is irrelevant, just that other factors may be in play and I need a different kind of graph. Likewise Melbourne (Vic) was omitted because it elected a Greens candidate in 2010.

Finally, any seat with a non-ALP-vs-Coalition margin in 2007 or 2010 was also omitted: Batman (Vic) and Grayndler (NSW) (second place Greens, 2010), Melbourne (Vic) (again) (second place Greens, 2007) and O’Connor (WA) (Nationals win over Liberals, 2010, after the WA Nats formed a breakaway from Warren Truss’s leadership). These were omitted because I calculated the 2010 2PP swings from the 2010 and 2007 2PP margins and didn’t want to extract the necessary major parties’ support by calculating back-flows from eventual 2PP stats. If you guys want it done, do it yourself.

Data Dump

Q&A Polling History 2013


 
Labor
Coalition
Greens
4/02/2013
36%
44%
10%
11/02/2013
36%
41%
14%
18/02/2013
38%
44%
12%
25/02/2013
30%
44%
10%
4/03/2013
35%
45%
10%
11/03/2013
33%
44%
11%
18/03/2013
33%
48%
11%
25/03/2013
35%
46%
11%
15/04/2013
33%
45%
11%
22/04/2013
28%
47%
11%
29/04/2013
33%
44%
10%
13/05/2013
31%
46%
12%
27/05/2013
29%
44%
11%
3/06/2013
30%
40%
10%
10/06/2013
36%
46%
10%
17/06/2013
33%
45%
9%
24/06/2013
35%
48%
10%
1/07/2013
37%
46%
9%
8/07/2013
37%
45%
9%
15/07/2013
38%
45%
9%
22/07/2013
33%
45%
11%
29/07/2013
35%
43%
9%
5/08/2013
34%
43%
10%
12/08/2013
33%
45%
10%
19/08/2013
35%
45%
10%
26/08/2013
36%
46%
10%

2010 Electoral Statistics

 
Seat
Swing to Labor
Margin
Adelaide (SA) -0.84 8.53
Aston (Vic) 3.29 5.05
Ballarat (Vic) 3.55 8.15
Banks (NSW) -9.63 11.08
Barker (SA) -3.43 9.45
Barton (NSW) -5.24 12.1
Bass (Tas) 5.74 1
Bendigo (Vic) 3.4 6.13
Bennelong (NSW) -4.52 1.4
Berowra (NSW) -7.26 8.94
Blair (Qld) -0.24 4.48
Blaxland (NSW) -6.14 18.37
Bonner (Qld) -7.35 4.53
Boothby (SA) 2.18 2.93
Bowman (Qld) -10.35 0.04
Braddon (Tas) 6.04 1.44
Bradfield (NSW) -4.73 13.45
Brand (WA) -2.29 5.62
Brisbane (Qld) -7.89 6.76
Bruce (Vic) -0.2 8.32
Calare (NSW) 1.31 12.05
Calwell (Vic) 0.39 19.33
Canberra (ACT) -2.67 11.82
Canning (WA) 3.39 5.58
Capricornia (Qld) -9.03 12.71
Casey (Vic) 1.75 5.93
Charlton (NSW) -0.2 12.87
Chifley (NSW) -8.32 20.66
Chisholm (Vic) -1.27 7.38
Cook (NSW) -6.09 6.57
Corangamite (Vic) -0.44 0.85
Corio (Vic) 5.29 8.93
Cowan (WA) -4.58 1.71
Cowper (NSW) -8.04 1.23
Cunningham (NSW) -4.96 18.13
Curtin (WA) -2.62 13.57
Dawson (Qld) -5.64 3.21
Deakin (Vic) 1 1.41
Dickson (Qld) -5 0.13
Dobell (NSW) 1.17 3.9
Dunkley (Vic) 3.02 4.04
Eden-Monaro (NSW) 0.84 3.4
Fadden (Qld) -3.99 10.2
Fairfax (Qld) -3.94 3.01
Farrer (NSW) -3.34 11.17
Fisher (Qld) -1.03 3.1
Flinders (Vic) -0.86 8.25
Flynn (Qld) -3.74 0.16
Forde (Qld) -4.54 2.91
Forrest (WA) -2.91 5.83
Fowler (NSW) -9.49 18.25
Franklin (Tas) 6.34 4.48
Fraser (ACT) -0.87 15.07
Fremantle (WA) -3.44 9.14
Gellibrand (Vic) 2.44 21.46
Gilmore (NSW) -1.25 4.07
Gippsland (Vic) -5.54 5.91
Goldstein (Vic) -0.42 6.05
Gorton (Vic) 0.94 21.22
Greenway (NSW) 5.38 4.5
Grey (SA) -6.73 4.43
Griffith (Qld) -3.86 12.32
Groom (Qld) -10.31 8.22
Hasluck (WA) -1.83 1.26
Herbert (Qld) -1.96 0.21
Higgins (Vic) 0.29 7.04
Hindmarsh (SA) 0.65 5.05
Hinkler (Qld) -8.7 1.69
Holt (Vic) 1.6 11.63
Hotham (Vic) 0.5 13
Hughes (NSW) -3.01 2.16
Hume (NSW) -4.56 4.16
Hunter (NSW) -3.44 15.92
Indi (Vic) -0.75 9.19
Isaacs (Vic) 3.33 7.69
Jagajaga (Vic) 2.54 8.98
Kingsford Smith (NSW) -8.13 13.29
Kingston (SA) 9.49 4.42
Kooyong (Vic) 1.98 9.53
La Trobe (Vic) 1.42 0.51
Lalor (Vic) 6.62 15.53
Leichhardt (Qld) -8.58 4.03
Lilley (Qld) -5.41 8.59
Lindsay (NSW) -5.66 6.78
Lingiari (NT) -7.46 11.16
Longman (Qld) -5.49 3.57
Lyons (Tas) 3.51 8.78
Macarthur (NSW) -2.3 0.72
Mackellar (NSW) -3.3 12.42
Macquarie (NSW) -8.3 7.04
Makin (SA) 4.5 7.7
Mallee (Vic) -3.14 21.27
Maranoa (Qld) -8.45 14.44
Maribyrnong (Vic) 1.54 15.32
Mayo (SA) -0.29 7.06
McEwen (Vic) 5.33 0.01
McMillan (Vic) 0.38 4.79
McPherson (Qld) -1.45 8.83
Melbourne Ports (Vic) 0.41 7.15
Menzies (Vic) -2.7 6.02
Mitchell (NSW) -5.57 11.59
Moncrieff (Qld) -3.48 14.01
Moore (WA) -2.02 9.17
Moreton (Qld) -3.62 4.75
Murray (Vic) -2.09 18.26
Newcastle (NSW) -3.42 15.91
North Sydney (NSW) -8.68 5.38
Oxley (Qld) -8.36 14.13
Page (NSW) 1.83 2.36
Parkes (NSW) -5.82 13.04
Parramatta (NSW) -2.51 6.88
Paterson (NSW) -3.82 1.51
Pearce (WA) 0.21 9.07
Perth (WA) -2.97 8.85
Petrie (Qld) 0.46 2.05
Port Adelaide (SA) 0.28 19.75
Rankin (Qld) -6.33 11.74
Reid (NSW) -14.12 16.8
Richmond (NSW) -1.88 8.87
Riverina (NSW) -1.94 16.23
Robertson (NSW) 0.89 0.11
Ryan (Qld) -3.34 3.82
Scullin (Vic) 1.4 20.85
Shortland (NSW) -1.89 14.74
Solomon (NT) -1.94 0.19
Stirling (WA) -4.26 1.29
Sturt (SA) -2.49 0.94
Swan (WA) -2.42 0.11
Sydney (NSW) -2.43 19.5
Tangney (WA) -3.64 8.68
Throsby (NSW) -11.35 23.46
Wakefield (SA) 5.36 6.59
Wannon (Vic) 0.18 7.47
Warringah (NSW) -3.59 9.5
Watson (NSW) -11.19 20.33
Wentworth (NSW) -11.01 3.85
Werriwa (NSW) -8.49 15.24
Wide Bay (Qld) -7.14 8.47
Wills (Vic) 0.23 22.41