instruere...inlustrare...delectare Disputations

Thursday, August 09, 2012

What are the odds?

Consider an election in which N votes are cast, each for one of two candidates, A and B. The election can be modeled as a set of N independent draws from a binomial distribution in which the probability of a vote for Candidate A is p (between 0 and 1 inclusive) and the probability of a vote for Candidate B is (1-p).

If N is even, the probability of a tie is given by the formula:

P(tie) = (N)! * ((N/2)!)^(-2) * (p-p^2)^(N/2)

If I've computed everything correctly, the P(tie) curves as a function of number of votes N, for different probabilities of a vote for Candidate A p, look like this:
The blue curve, for p=0.5, is equivalent to the case where every vote is cast by flipping a fair coin. In that case, the probability of a tie falls off exponentially with the number of votes. If 10,000 votes are cast, the probability of a tie is 0.8%. That would generally be considered an improbable outcome -- though of course the probability of it happening at least once rises as the number of such elections increases. In any set of 52 elections with 10,000 voters flipping fair coins, the odds of a tie are about 1 in 3.

Given how many elections are held each year in the U.S. alone, that might make it seem like there should be a lot of ties, at least in local elections with relatively small numbers of voters. But note that the blue curve represents the highest probability of a tie assuming a binomial voting distribution. As the other curves show, if one candidate has even a slight edge, the probability of a tie falls off dramatically. In elections of 100,000 votes, voters voting 51%-49% will produce a tie about half a billion times less often than voters voting 50%-50%.

(And if you're wondering how voters voting 51%-49% could ever produce a tie -- or, for that matter, how an even number of voters voting 50%-50% could ever not produce a tie -- recall those percentages are probabilities associated with an a priori distribution, not the posterior statistics of the election.)