PDA

View Full Version : problem with variance


mnb96
Nov4-10, 06:53 PM
Hello,
we are given N independent random variables z_i defined as follows:

z_i = \theta + v_i

where the r.v. v_i are zero-mean normal distributions v_i \sim N(0,\sigma^2).

I want to compute the variance of the estimator

\hat{\theta}=\frac{1}{n}\sum_{i=1}^n z_i

However I can't seem to get the right result (I get always zero).

I computed first E(\hat{\theta})^2=\theta^2.

Then I try to compute E(\hat{\theta^2}) as follows:

\frac{1}{n^2}E\left[\left(\sum_{i=1}^n z_i \right)^2\right] = \frac{1}{n^2}E\left[\left(\sum_{i=1}^n (z_i)^2 \right) + \left(\sum_{i=1}^n z_i \right) \left( \sum_{j\neq i} z_j \right) \right]

= \frac{1}{n^2}E\left[\sum_{i=1}^n z_i^2 \right] + \frac{n-1}{n}\theta^2

= \frac{1}{n^2}E\left[\sum_{i=1}^n (\theta^2 +2\theta v_i + v_i^2) \right] + \frac{n-1}{n}\theta^2

= \frac{1}{n}\theta^2 + \frac{n-1}{n}\theta^2

From this we get Var(\hat{\theta})=E(\hat{\theta}^2)-E(\hat{\theta})^2 = 0.
Where is the mistake?

jbunniii
Nov4-10, 10:08 PM
\frac{1}{n^2}E\left[\sum_{i=1}^n (\theta^2 +2\theta v_i + v_i^2) \right] + \frac{n-1}{n}\theta^2

= \frac{1}{n}\theta^2 + \frac{n-1}{n}\theta^2



This is wrong. You dropped the v_i^2 term.

mnb96
Nov5-10, 01:47 AM
uh...that's true! Thanks.

E(v_i^2) = \frac{1}{\sqrt{2\pi \sigma^2}}\int_\mathbb{R} x^2 e^\frac{-x^2}{2\sigma^2} dx

This integral is indeed > \\ 0

jbunniii
Nov5-10, 11:14 AM
uh...that's true! Thanks.

E(v_i^2) = \frac{1}{\sqrt{2\pi \sigma^2}}\int_\mathbb{R} x^2 e^\frac{-x^2}{2\sigma^2} dx

This integral is indeed > \\ 0

In fact, E(v_i^2) = \sigma^2.