More Iranian election statistics
It’s looking more and more as if the official Iranian election returns were at least partially fictional. I wrote last week about one unconvincing statistical argument for fraud; now a short paper by Bernd Beber and Alexandra Scacco offers more numbers and makes a stronger case.
Keeping in mind that I like their paper a lot, let me say something about a part of it where I thought a bit more justification was needed.
Consider the following three scenarios for generating 116 digits that are supposed to be random:
- Digits produced by 116 spins of a spinner labeled 0,1,…,9.
- Final digits of vote totals from 116 Iranian provinces.
- Final digits of vote totals from U.S. counties.
Now consider the following possible outcomes:
- A. Each digit appears either 11 or 12 times.
- B. 0 appears only 4% of the time, and the other digits appear roughly 10% of the time.
- C. 7 appears 17% of the time, 5 appears only 4% of the time, other digits appear roughly 10% of the time.
Which outcome should make you doubt that the digits are truly random?
In scenario 1, I think B and C are suspicious; that level of deviation from the mean is more than you’d expect from random spins. Outcome B would make you suspect the spinner was biased against landing on 0, and C would make you think the spinner was biased towards 7 and against 5.
But of course, outcome A is much more improbable (or so my mental calculation tells me) than either B or C. So why does’t it arouse suspicion? Because there’s no apparent mechanism by which a spinner could be biased to produce near-exactly uniformly distributed results like this. Your prior degree of belief that the spinner is “fixed” to produce this behavior is thus really low, and so even after observing A your belief in the spinner’s fairness is left essentially unchanged.
In scenario 3, I don’t think any of the three outcomes should raise too much suspicion. Yes, the probability of seeing deviations from uniformity as large as those in C in random digits is under 5%. But we have a strong prior belief that U.S. elections aren’t crooked — in this case, I think it’s fair to say that scenarios A,B, and C are all evidence that the digits being faked, but not enough evidence to raise the very small prior to a substantial probablity of fraud.
Scenario 2, the one Beber and Scacco consider, is the most interesting. Outcome C is the one they found. In order to estimate the probability of fraud in a Bayesian way, given outcome C, you need three numbers:
- The probability of seeing outcome C from random digits;
- The probability of seeing outcome C from digits made up from whole cloth at the ministry;
- The probability — prior to any knowledge of the election results — that the Iranian government would release false numbers.
The third question isn’t a mathematical one, but let’s stipulate that the answer is substantial — much larger than the analogous probability in the United States.
The first question is the one Beber and Scacco assess in their paper; they get an answer of less than 5%. That sounds pretty damning — deviations like the “extra 7s” seen in the returns would arise less than 1 in 20 times from authentic election numbers. In fact, outcomes A,B and C are all pretty unlikely to arise from random digits.
But outcome C is evidence for fraud only if it’s more likely to arise from fake numbers than real ones. And here we have an interesting question. Beber and Scacco observe that, in practice, people are bad at choosing random digits; when they try, they tend to pick some numbers more frequently than chance would dictate, and some less. (Their cites for this include the interesting paper by Philip J. Boland and Kevin Hutchinson, Student selection of random digits, Statistician, 49(4): 519-529, 2000.)
So on these grounds it seems outcome C is indeed good evidence for faked data. But note that the Boland-Hutchinson data doesn’t just say people are bad at picking random digits — it says they are bad in predictable ways at picking random digits. Indeed, in each of their four trial groups, participants chose “0″ — which just doesn’t “feel random” — between 6.5% and 7.5% of the time, substantially less than the 10% you’d get from a random spinner.
So outcome B, I think, would clearly be evidence for fraud. But outcome C is a little less cut-and-dried. Just as it’s not clear what mechanism would make a fixed spinner prone to outcome A, it’s not clear whether it’s reasonable to expect a person trying to pick random numbers to choose lots of numbers ending in “7″. In Boland and Hutchinson’s study, that digit came up just about exactly 10% of the time.
Here’s one way to get a little more info; let’s say we believe that people trying to imitate random numbers choose 0 less often than they should. If the Iranian election digits had an overpopulation of 0, you might take this to be evidence against the made-up number hypothesis.
So I checked — and in fact, only 9 out of the 116 digits from the provincial returns, or 7.7%, are 0. Point, Beber and Scacco.
In the end, it’ll take people with better knowledge of Iranian domestic politics — that is, people with more reliable priors — to determine what portion of the election numbers are fake. But Beber and Scacco have convinced me, at least, that the provincial returns they studied are more consistent with made-up numbers than with real ones.
Here’s a post from Andrew Gelman’s blog in which Beber and Scacco explain what their tests reveal about the county-level election data.
Update: A more skeptical take on Beber and Scacco from Zach at Alchemy Today, who also makes the point that in order to get this question right it’s a good idea to think about the way in which people’s attempts to choose random numbers deviate from chance. I think his description of Beber and Scacco’s reasoning as “bogus” is too strong, but his observation that the penultimate digits of the state totals for Obama and McCain are as badly distributed as the final digits of the Iran numbers is a good reminder to be cautious.
Re-update: Beber remarks on Zach’s criticisms here.

Zach on 25 Jun 2009 at 8:42 am #
If you read their previous work on Nigerian election, they postulate that humans generating random numbers will prefer the digits 1,2, and 3 and avoid the digits 6,8,9, and 0. They will also not repeat sequences frequently enough and use too many adjacent numbers. Note that the numbers 7 and 5 don’t appear here.
The thing is that it’s almost certain that you can find a pattern that meets some of these criteria in any set of random numbers. Your A/B/C scenarios above are all equally unlikely — if any of them occurred, Beber and Scacco would’ve written the same paper. There are far more than 20 unique, rare phenomena all with the same (3.5%) probability. The chances of one of them occurring in a random set of data are 100%.
In this article, they identify a rare phenomena, calculate it’s probability of occurring randomly, and imply that those are the odds that the election was fair. This is not a valid statistical method; it’s numerology.
Chris on 14 Aug 2009 at 12:30 pm #
Looking at the Iranian election results, I performed a chi-square test on the distribution of the last digits of the reported numbers, under the null hypothesis that they should be uniformly distributed. They aren’t uniformly distributed, but the degree to which that is true is interesting, and the distribution is worth examining.
First, I found a significance level of just at 5% using the chi-square test (anyone confirm or deny this?). So, this is just at the boundary of what many scientists would call a “significant” result; I certainly would not call the evidence damning.
Second, the distribution itself was quite interesting. The larger digits – 7 and 8 especially – appeared more frequently than one would expect, and the lesser digits appeared less frequently. But when humans choose single digits randomly, they tend to choose 7 most, but also 3 (that is, we tend to avoid the center of the range of numbers, and the ends). So why didn’t 2 or 3 show up more frequently than expected?
Probably a reasonable follow-up study (and possibly a very useful one for detecting fraud in future elections) is to study how people generate random numbers when (a) the numbers have multiple digits and (b) when they have to achieve the goal of making one candidate win while not making the election results look “too” fraudulent. (That is, don’t rely on comparisons to abstract situations like choosing random numbers in a classroom with no objective in mind, but mimic the conditions of an election.) Anybody have some funding?
I could plausibly believe the idea that people generate numbers for the intended “winner” of the election that end in larger digits (unconsciously, “bigger” numbers == “win”), but I have no evidence supporting this idea. If the numbers for the “winner” of the election were massaged while others were left alone, this could result in the observed increased frequency of larger last digits (but this is very speculative). Since this idea occurred to me while writing this post, I do not have any numerical evidence. I will go back to the election results and look at how the digits in results are distributed for each candidate; could be interesting, though I do not think that any such result would definitively indicate election fraud.