1

I know that the variance of the sample mean is:

$$\frac{\sigma^2}{n}$$

And that the unbiased estimator for that expression is:

$$\frac{\sigma^2}{n-1}$$

The variance of the sample proportion is:

$$\frac{p(1-p)}{n}$$

Does an unbiased estimator of variance of the sample proportion also need to have (n-1) in the denominator, like the unbiased estimator of the variance of the sample mean?

I feel the resoning for the denominator should be applicable for both situations, but I haven't seen it mentioned anywhere...

Magnus
  • 703
  • $\frac{\sigma^2}{n-1}$ is not correct, as since you know $\sigma^2$ there is no bias in $\frac{\sigma^2}{n}$, while if you do not then you cannot use it in an estimator. – Henry Dec 31 '20 at 15:34
  • Sure, I should probably have specified that the "sample" variance needs to be divided by n-1 in order for us to use it as an unbiased estimator, my question still stands. – Magnus Dec 31 '20 at 15:37

2 Answers2

1

If $\hat{p}$ is the sample proportion, then $n\hat{p} \sim \text{Binomial}(n, p)$ so

$$E[\hat{p}(1-\hat{p})] = E[\hat{p}] - E[\hat{p}^2] = E[\hat{p}] - \text{Var}(\hat{p}) - E[\hat{p}]^2 = p(1-p) (1 - \frac{1}{n})$$ so it seems that the unbiased estimator of $\frac{p(1-p)}{n}$ would be $$\frac{\hat{p}(1-\hat{p})}{n-1}.$$

I might have made a miscalculation somewhere though.

angryavian
  • 89,882
  • That does seem legit but I saw another answer on a related question (though now I can't find it) claiming the opposite. I'll hold off accepting the answer for a day or something just in case, no offense. – Magnus Dec 31 '20 at 15:55
  • Also, I'm a bit confused about this step: $E[\hat p]−E[p^2]=E[\hat p]−Var(\hat p)−E[p]^2$ Where did the Var(p) come from? – Magnus Dec 31 '20 at 16:04
  • @Magnus $\text{Var}(\hat{p}) = E[\hat{p}^2] - E[\hat{p}]^2$. – angryavian Dec 31 '20 at 16:21
  • $Var(\hat p)=E(\hat p^2)-(E(\hat p))^2$ if I'm not mistaken, are we equating $(E(\hat p))^2$ with $E[\hat p]^2$? – Magnus Dec 31 '20 at 16:41
  • 1
    @Magnus When I write $E[\hat{p}]^2$ I mean $(E[\hat{p}])^2$. – angryavian Dec 31 '20 at 17:13
  • Okay, but then how can $E(p^2)=(E(p))^2$, as is implied in the first step? – Magnus Dec 31 '20 at 17:16
  • 1
    No, $E[\hat{p}^2] = \text{Var}(\hat{p}) + (E[\hat{p}])^2$. – angryavian Dec 31 '20 at 17:25
  • Okay, I can accept that $E(p)-E(p^2)=E(p)-(E(p^2)-(E(p))^2)-(E(p))^2)$. How do I make the final transition to equate this with $(E(p^2)-(E(p))^2)(1-\frac{1}{n})$? – Magnus Dec 31 '20 at 18:01
  • 1
    @Magnus $E[\hat{p}] = p$ and $\text{Var}(\hat{p}) = \frac{p(1-p)}{n}$ because $n\hat{p} \sim \text{Binomial}(n,p)$. – angryavian Dec 31 '20 at 18:04
  • Okay I've managed to work through the first row of formulas. Perhaps I'm just dense, but how does this imply that the unpiased estimator is $\frac{\hat p(1-\hat p)}{n-1}$? – Magnus Dec 31 '20 at 19:41
  • okay, i figured it out, $\frac{1-\frac{1}{n}}{n-1}=n$ – Magnus Dec 31 '20 at 19:58
0

If you have a random variable $X$ with a binomial distribution with parameters $n$ and $p$, then $\mathbb E\left[\frac{X}{n} \right]=p$, so the sample proportion $Y=\frac{X}{n}$ is an unbiased estimator of $p$.

Meanwhile $\mathrm{Var}\left(Y \right) = \mathrm{Var}\left(\frac{X}{n} \right) = \frac{p(1-p)}{n}$ is the variance of the sample proportion,

implying $\mathbb E[Y^2] = \frac{p(1-p)}{n}+\frac{p^2}{n^2}$,

so $\mathbb E\left[Y(1-Y) \right] = p - \frac{p(1-p)}{n}-\frac{p^2}{n^2} = p(1-p)\frac{n-1}{n} $ and thus $\mathbb E\left[\frac{Y(1-Y)}{n-1} \right] = \frac{p(1-p)}{n}$,

showing $\frac{Y(1-Y)}{n-1} $ is an unbiased estimator of the variance of the sample proportion $\frac{p(1-p)}{n}$

Henry
  • 157,058