Show E[E(X|Y)]=E[X]

951 Views Asked by At

Show E[E(X|Y)]=E[X]

Now if X and Y are independent then it is very straightforward as E(X|Y)]=E[X]. However is there a better explanation to this ? Can we prove this mathematically ?

What if X and Y are not independent ? Will it hold ?

1

There are 1 best solutions below

4
On

This is called the Law of total expectation. First, note that

$$E[X|Y]=\int_{-\infty}^{\infty}p_{X|Y}(x|y)xdx\tag{1}$$

where $p_{X|Y}(x|y)$ is the conditional probability density function. Then note that

$$E[E[X|Y]]=\int_{-\infty}^{\infty}E[X|Y=y]\;p_Y(y)dy\tag{2}$$

Combining $(1)$ and $(2)$ gives

$$\begin{align}E[E[X|Y]]&=\int_{-\infty}^{\infty}\int_{-\infty}^{\infty}p_{X|Y}(x|y)p_Y(y)x\,dxdy\\&=\int_{-\infty}^{\infty}x\int_{-\infty}^{\infty}p_{XY}(x,y)\,dy\,dx\\&=\int_{-\infty}^{\infty}xp_X(x)dx\\&=E[X]\tag{3}\end{align}$$

where I've used $p_{X|Y}(x|y)p_Y(y)=p_{XY}(x,y)$, and $p_X(x)=\int_{-\infty}^{\infty}p_{XY}(x,y)dy$.