# Standard error of weighted mean

I found it on wikipedia page: https://en.wikipedia.org/wiki/Weighted_arithmetic_mean

Under Statistical properties section, the variance of weighted sample mean is:

$$\sigma_\bar x ^2 = \sum w_i^2\sigma_i^2$$ $\sigma_i$ is stated as each observations' variance.

However, I think it actually should be the standard error of the observations. Also, if it's for variance, the formula should be without the square:

$$\sigma_\bar x ^2 = \sum w_i \sigma_i^2$$

The squared one should be for standard error: $$se_\bar x ^2 = \sum w_i^2se_i^2$$

This is also used in the book "Data Analysis Using Regression and Multilevel/Hierarchical Models" by Andrew Gelman and Jennifer Hill, page 205. Here, they used standard errors.

No derivation was given, but here is how I would do it:

Imagine a set of $N_i$ were sampled from $i$ independent distributions and aggregated together as a new sample. Then the weighted mean would just be the mean of this new sample.

If $w_i = N_i / N$

Then $\sigma_\bar x^2 = \sum w_i \sigma_i^2$

Since $\sigma_i^2 = se^2 N_i$

Then

$\sigma_\bar x^2 = \sum w_i se^2 N_i$

So $se_\bar x = \sqrt{\sigma_\bar x^2 / N} = \sqrt{\sum w_i^2 se_i^2}$

So is there anything wrong of my derivation above? Or I'm understanding something completed wrong?

Thank you.

• For independent observations it is not the case that $\sigma_\bar x^2 = \sum w_i \sigma_i^2$. (If this were so, then in the case $N_i=1$ and all $\sigma_i^2=\sigma^2$ being equal you could deduce that $\sigma_\bar x^2 = \sigma^2$, "proving" that averaging doesn't improve estimates of the mean.) Since you assert this at the outset, this might be the best place to revisit your calculations. The Wikipedia article you reference presents the correct formulas. – whuber Oct 9 '17 at 19:05
• Thanks for the comment. I think I got confused about standard error and sample variance. Is it ok to say that sample variance (the generated mixed sample from different distributions), $s^2 = \sum w_w \sigma^2$ ? – Fei H Oct 10 '17 at 17:58