1

Say that you're making a political research, and you want to know how many people vote to Party A and how many vote to Party B. (There are only two choices.)

You make a random survey of 10 people, and find that 1 out of your 10 votes A, while the other 9 vote B.

What would you conclude is the average expected ratio of A voters in the general population?

Most people's intuition would say 0.1. But I calculated it and it came out as 0.0909090, i.e. 1/11. It's definitely possible I made a mistake in my calculation. Can you tell me whether my result makes sense?

kjetil b halvorsen
  • 63,378
  • 26
  • 142
  • 467
Ram Rachum
  • 661
  • 2
  • 6
  • 10
  • 8
    It would make answering easier if you specified how did you do your calculations. – nico Aug 12 '11 at 11:55
  • 1
    When you say the "average expected ratio" do you mean the proportion in the population that votes for A? If so, 0.1 would be the correct estimate. If you mean the ratio of A votes to B voters, it would be 1/9. I'm not exactly sure what 1/11 would be reflecting. – Macro Aug 12 '11 at 13:11
  • 1
    You seem to already have an account here, "[cool-RR](http://stats.stackexchange.com/users/1523/cool-rr)". Do you want me to merge? –  Aug 12 '11 at 14:25
  • 1
    @mbq: Sure, thanks. (I changed OpenID to `ram.rachum.com`.) – Ram Rachum Aug 12 '11 at 15:55

1 Answers1

2

Call the probability of voting A as $\theta$, and assume you have no other information for it. You then observe out of 10, 1 votes for A. The posterior probability density function for $\theta$ then becomes $$p(\theta) = \frac{\theta^1(1-\theta)^9}{\int_0^1x^1(1-x)^9dx}$$ or, $$p(\theta) = \frac{\theta^1(1-\theta)^9}{B(2,10)}=2/12$$

This is the beta distribution. Why are we getting a counter-intuitive result? Well, that is because we assumed a uniform prior on $\theta$, basically saying that we believe the value of $\theta$ is equally likely to be anywhere between 0 and 1. i,e., $p_{\text{Prior}}(\theta) = 1 \forall\{\theta \in R ,0\le\theta\le1\}$. If you have some other prior on $\theta$, you will get a different result. I don't know what prior you assumed for your answer, but this is how you should do the calculation in a Bayesian framework.

highBandWidth
  • 2,092
  • 2
  • 21
  • 34
  • 2
    The idea's right although the equations make no sense. (The second equation is true when $\theta = 0.471566$, but where did that come from?) 2/12 is the Bayes estimate using a Beta(1,1) prior. Similarly, 1/11 is the Bayes estimate using a Beta(0,1) prior. In effect, that's just a fancy way of saying you can get 1/11 as the answer if you assume you previously had sampled one person and they voted for Party B. [Captain Statistics](http://stats.stackexchange.com/questions/423/what-is-your-favorite-data-analysis-cartoon/5006#5006) to the rescue! – whuber Aug 12 '11 at 15:25
  • @whuber, Beta(0,1) does not correspond to polling 1 person and finding they vote for B. That'd be Beta(1,2). What do you think the answer should be? – highBandWidth Aug 12 '11 at 15:55
  • The O.P. is asking us to guess how he made a mistake: until he provides additional information, any answer is merely speculation. That's why I haven't weighed in on the original question. A Beta(0,1) prior corresponds to a one-person sample in the sense that the Bayes estimate (for observing $k$ successes out of $n$) of $k/(n+1)$ is identical to the standard estimate (a mean) obtained when observing $k$ successes in a sample of $n+1$. That's exactly what would happen if we started with $0$ successes out of $1$ and supplemented that dataset with $k$ out of $n$ additional observations. – whuber Aug 12 '11 at 16:03
  • I assumed a uniform prior. – Ram Rachum Aug 12 '11 at 16:06
  • @Ram Then highBandWidth has identified the cause of the mistake, and you should fully credit this answer: the uniform is Beta(1,1), so the correct estimate when observing $k=1$ successes out of $n=10$ observations is $(k+1)/(n+1)$ = $2/12$, not $1/11$. – whuber Aug 12 '11 at 20:05