(Note: this calculator is outdated as it’s based off preference flows at the 2019 Australian federal election. If you’re looking for the latest calculator, click here)
In Australian politics, the two-party-preferred (2pp) refers to how many voters place a Labor candidate over the Liberal/National candidate or vice versa. 2pp estimates are often used to produce a better overview of the Labor vs Liberal/National contest.
Under the preferential voting system, voters rank the candidates on their ballot in order of which ones they prefer to be elected first. For example, let’s say we had four candidates running in an electorate, from the Labor, Liberal, National and Democrat parties.
A hypothetical voter might prefer that the National candidate is elected first of all, but if the National can’t win, they would prefer that the Liberal is elected, and then prefer the Democrat candidate over the Labor candidate. This voter would fill in their ballot as such:
- FLUGGE, Trevor
NATIONAL - TUCKEY, Wilson
LIBERAL - PEEBLES, Shyama
AUSTRALIAN DEMOCRATS - CHANCE, Kim
AUSTRALIAN LABOR PARTY
In a House of Representatives (the lower house, where government is formed) election, all ballots are first processed and counted, and a primary vote (or first-preference vote) tally produced. This refers to the % of voters who put one party first. For example, if one in five voters put the National candidate first, then the National Party would have a primary vote of 20%.
Once all ballots have been processed and counted, the candidate with the lowest primary vote is sequentially eliminated, and their voters’ ballots will be transferred to their next preference. For example, let’s say that in this election, each party has a primary vote of:
The Democrat candidate will be eliminated first, and their votes transferred to each voter’s second preference. For simplicity’s sake, let’s assume that half of Democrat voters placed Labor 2nd, while a quarter each placed the Liberal and National candidates second.
Note that this is entirely controlled by who the voters place second on their ballot – candidates and parties do not have any control over where preferences go. A party or candidate may recommend preferences using how-to-votes and other material, but where the ballot travels next is entirely up to the voter.
You may occasionally hear of “preference deals” and “(party) directs preferences to (party)” in the news or other media. This only refers to the parties’ ability to recommend that their voters put Party A over Party B. If a voter decides to ignore this recommendation and preference Party B over Party A, their ballot will go to Party B’s candidate at full value.
The proportion of primary votes for a certain party which are then transferred to another party is also known as the preference flow. In this case, the preference flow for Democrat votes would be 50% Labor, 25% Liberal and 25% National.
While preference flows are referred to as percentages, note that in the House of Representatives, there is no partial vote transfer. If you hear that the preference flow from the Greens to Labor is 80%, that doesn’t mean that 80% of each Green vote goes to Labor. It means that four of five (80%) Greens voters put the Labor candidate ahead of the other candidate on their ballot, while one in five (20%) put the other candidate ahead of Labor.
Preference flows are a useful way to calculate the outcome of a preferential-voting contest. For example, if I told you that in an election, Labor won 48%, the Liberals won 32% and the Nationals won 20%, if you know what the National -> Liberal preference flow is, you can calculate the final Labor-versus-Liberal result in that election.
Speaking of which, let’s finish our example preferential-voting election. As the National candidate has the lowest vote share of the remaining candidates, he is eliminated. Since our hypothetical voter from earlier voted 1 National 2 Liberal, their vote is then transferred to the Liberal. Had they instead voted 1 National 2 Democrat 3 Labor 4 Liberal, their vote would instead be transferred to Labor (as the Democrat candidate has already been eliminated).
For simplicity’s sake, let’s assume that 80% of all voters who voted 1 National or 1 Democrat 2 National then places the Liberal candidate over the Labor candidate.
The vote shares of the final two candidates is often referred to as the two-candidate-preferred, or 2cp for short. It is sometimes also referred to as the two-party-preferred; however this can be confusing for reasons explained below.
Because Labor and Coalition parties tend to have the largest vote shares at Australian elections, in most electorates the race comes down to a Labor-vs-Coalition contest (as parties/candidates with smaller shares of the vote get sequentially eliminated).
In these electorates, it’s easy to figure out what share of the population prefers Labor over the Coalition or vice versa, using the two-candidate-preferred (2cp) figure produced through the instant-runoff system.
However, in some electorates, the final two candidates may not consist of a Labor and a Coalition candidate. Candidates from one of the smaller parties (e.g. Greens, One Nation, Katter’s Australian, Centre Alliance) may receive more votes (or more preferences) than one or both major parties.
Additionally, there are instances when the final-two pairing ends up being one Coalition candidate against another.
When the final-two pairing is not a Labor versus Coalition contest, this is known as a non-classic contest.
For all non-classic electorates, the Australian Electoral Commission (AEC) will go back through the ballots, and do a count of how many voters placed the Labor candidate over the Coalition candidate(s), or vice versa.
This allows the AEC to determine what share of voters ‘prefer’ Labor over the Coalition in every electorate. This proportion is known as the two-party-preferred or 2pp for short.
The AEC also calculates statistics such as how many voters for each party placed the Coalition over Labor or vice versa, allowing the determination of two-party preference flows. For example, 82.21% of Greens voters placed Labor over the Coalition at the 2019 federal election.
Two-party-preferred can be quite a useful statistic both at the seat level and nationally. For example, if you live in a non-classic seat with an Independent MP, and said Independent MP is retiring at the next election, you might be interested to know if your seat is more likely to fall to Labor or to the Coalition. In the event of a hung parliament, minor-party and independent MPs may be interested to know if their seat’s voters would prefer that they support a Labor or Coalition government.
Two-party-preferred also helps make sense of changes in primary vote share. If I came up to you and told you that Labor’s primary vote has declined by 3 points, with the Coalition gaining one point, the Greens gaining one point and other minor parties collectively gaining one point, it’s not immediately apparent what that means for most seats (which are Labor-vs-Coalition contests).
On the other hand, if I told you that there’s a two-party-preferred swing of 1.7% against Labor, you can look up the two-party-preferred of all electorates at the last election and get some idea of which seats might fall.
Note that two-candidate-preferred and two-party-preferred are not the same thing. While they can be the same if the final two candidates are Labor and a Coalition candidate, two-candidate-preferred specifically refers to the final vote shares between the final two candidates in an electorate, while two-party-preferred refers to the proportion of voters in that electorate who prefer Labor over the Coalition or vice versa.
However, currently one pollster does not calculate a 2pp estimate (Resolve) while two other pollsters (Roy Morgan and Essential) appear to produce 2pp estimates using the less-accurate respondent-preferences method. There are two broad categories of estimating two-party-preferred for a given set of first-preference votes:
Last-election preference flows: This assumes that preferences from each minor party (or group of minor parties) will flow to a given major party at the same rate as the last election.
For example, if 82.2% of Green voters put Labor above the Coalition at the last election, this method assumes that 82.2% of Green voters will again put Labor above the Coalition at the next election.
Respondent-allocated preferences: This involves asking minor-party voters who they intend to preference, and then calculating a two-party-preferred estimate using said preference flows and the primary vote shares of each party.
Last-election preference flows has historically been more accurate than asking respondents who they intend to preference. Historically, a given party’s preference flows usually don’t shift much between elections. Additionally, minor party voters typically make up a small proportion of any sample and hence random noise significantly stuffs up estimates of a minor party’s preference flows.
Notably, Roy Morgan’s respondent-allocated preferences have skewed to Labor by quite a few points in the past (compared to last-election preference flows calculated using the published primary vote). The calculator below takes primary vote inputs and calculates an expected 2pp using preference flows at the 2019 federal election, with a few options to change the preference flows (within limits).
If you’re looking for our federal election forecast, that’s up here >>
If you want to batch-convert several sets of primary votes to a two-party-preferred figures, I’ve uploaded a spreadsheet here which contains the formulae to do so.
Enter the first-preference (i.e. primary vote) for each party/grouping below. Primary vote figures will be re-calculated such that they sum to 100%.
An error occurred!
Check to ensure that all fields have been filled in, and that no input is negative or greater than 100.
How much uncertainty is there in this estimate?
Historically, using preference flows from the last election has been the best method to estimate two-party-preferred. However, preference flows do shift from one election to another. To model this uncertainty, we use historical shifts in minor-party preference flows to randomly generate preference flow shifts, then calculate a 2pp using these and the primary vote figures above.
When the calculator is run, a sample of these 2pp estimates will be plotted below in a swarm plot.
This is not a model of polling error!
Keep in mind that this only models uncertainty in preference flows; it assumes that the primary votes above are exactly what each party gets. Primary vote data from polls etc also has the potential for error (especially polls taken far out from election day); therefore the 2pp uncertainty for a poll is usually much higher than what is displayed below.
Generate new sample
How does this work?
Firstly, the calculator takes the primary vote inputs and redistributes them such that they sum to 100. This is to handle pollsters which don’t drop the undecided vote (Essential) and pollsters who release rounded primary vote figures (which occasionally sum to 99 or 101). Note: dropping undecideds effectively assumes that undecided respondents will vote in a similar manner to decided respondents. This may or may not be an accurate assumption but it’s one that pretty much all pollsters make. For example, if you go onto a Newspoll methodology statement, you’ll see a section on undecided voters which says “x% were thus excluded from published voting-intention figures”.
Having said that, there is no long-term bias in Australian polling as a whole, with the few biases that exist having declined in recent elections. Hence, this is probably a valid assumption to make.
Secondly, it then uses two-party preference flows for each party/grouping to calculate a two-party-preferred estimate. This is a pretty simple process – multiply the preference flow (e.g. 0.822 Green -> Labor) by the primary vote for each minor party/grouping and add them to the primary vote for each major party. Preference flows used are either the ones for each party at the 2019 federal election, The default preference flow for all other parties + independents (Others/OTH in polling) will change depending on whether the UAP is included in others, or split out.
I may add options to customise the primary vote and preference flow for other minor parties if pollsters begin regularly asking about voting-intention for said parties separately. or custom preference flows if the user has set them.
As part of estimating the two-party-preferred, a leakage term is also included. In some seats, there were both Liberal and National Party candidates, with not all of their voters opting to preference the other over Labor. Hence, if a two-party-preference estimate for such seats is produced using (Liberal vote + National vote + preferences from other parties), it would over-estimate the Liberal/National two-party-preferred.
To deal with this, I simply compare the estimate based on the actual primary votes and preference flows to the actual two-party-preferred in 2019; my current estimate is that the Coalition’s 2pp is about 0.1% lower than in a world where every Liberal/National voter always placed the other Coalition party ahead of Labor in three-cornered contests.
Lib/Nat 2pp estimate using preference flows = 41.44% + 10.4% × 0.1779 + 3.08% × 0.6522 + 3.43% × 0.6514 + 8.31% × 0.493 = 51.63%
Actual Coalition 2pp = 51.53%
Leakage penalty = 51.63% – 51.53% = 0.1%
Thirdly, it generates 1 000 random preference-flow shifts. To do this, it uses historical variation in the preference flows of each minor party and the Others grouping, with each party split out from Others modelled separately. This is so that minor parties with significantly more or less volatility in their preference flows get modelled differently.
For example, the Greens preference flow has been fairly stable over time, while One Nation has shown that a chunk of its voters can change preferencing patterns fairly rapidly. The standard-deviation for each minor party is listed below:
GRN: 0.035
PHON/UAP: 0.1
OTH: 0.055 (0.068 if UAP is not split out)
It then dynamically produces a probability distribution for the preference flow of each minor party using the expected preference flow (either the one defined by the user or the 2019 data) and the variation in each minor party’s preference flows.
(In stats-speak: it uses method of moments to calculate α and β for a beta distribution using the mean and variance as inputs)
Fourthly, it uses the same method described above to calculate a two-party-preferred estimate using the primary vote inputs and the randomly-generated preference flows. Note that it does not randomly generate primary vote figures and therefore does not account for polling error.
Next, it samples the generated two-party-preferred and displays the sample in a swarm plot. This sampling is not random; due to issues with spacing, a small number of points are displayed in smaller devices (if your device is less than 400px wide, it should only display 25 points). Hence, there is a decent probability that a small random sample would be unrepresentative.
Instead, it orders the generated two-party-preferred from smallest to largest, and then samples at equal intervals. For example, if 99 points are to be displayed, it grabs the 10th smallest 2pp, then the 20th smallest 2pp, then the 30th smallest, etc until it has all the points needed. This ensures that a representative sample is produced, although it has the side effect of removing any outliers from the sample (and hence from the plot). For the purposes of a graphical representation, I don’t think it’s a particular issue that extreme outliers don’t appear in the swarm plot. The purpose isn’t to show exact points (which would be hard to do without overlapping) but to provide a general feel for the uncertainty in the 2pp estimate.
Finally, it then goes into the full sample of generated two-party-preferred, and grabs the 5th smallest and 5th largest two-party-preferred figures. It then uses these to construct a 99% confidence interval, which is a range in which we’d expect the two-party-preferred to be 99% of the time given the primary vote and preference flow inputs above. For reference, the “margin-of-error” you hear cited with some polls refers to a 95% confidence interval given some assumptions about polling. Namely, the assumption that the sampling is random, with every Australian voter having an equal probability of being sampled. Despite pollsters’ efforts to construct a representative sample, this is often not the case and hence the true 95% confidence interval is often somewhat wider than the margin-of-error claimed by pollsters.