Special case of the law of total expectation

115 Views Asked by At

Is this true : $E_{X|Y}[X|Y]=E_{Z|Y}[E_{X|Y,Z}[X|Y,Z]]$ ? I deduced it from the law of total expectation.

Thanks a lot !

1

There are 1 best solutions below

4
On

It is not true. $E(X|Y)$ is with respect to the distribution of $X|Y$ it's true, but $E(E(X|Y,Z))$ has the inner expectation with respect to $X|Y, Z$, and the outer expectation with respect to the joint distribution $Y, Z$. This is because $E(X|Y,Z)$ is a function of $Y, Z$ (in general, $E(X|Y)$ is a function of $Y$). We cannot subscript the expected value operator with the wrong random variable/distribution or a partial one as in $E_Z$, not allowed. So we would get $$\begin{split}E(E(X|Y,Z))&=E\left(\int_{-\infty}^\infty xg(x|y,z)dx\right)\\ &=\int_{-\infty}^\infty \int_{-\infty}^\infty \int_{-\infty}^\infty xg(x|y,z)f(y,z)dydzdx\\ &=\int_{-\infty}^\infty \int_{-\infty}^\infty \int_{-\infty}^\infty x f(x,y,z)dydzdx\\ &=\int_{-\infty}^\infty xf(x)dx\\ &=E(X)\end{split}$$

Indeed, this is a well-known result called the law of iterated expectation: $E(E(X|Y))=E(X)$.

If we wanted to force out the $E(X|Y)$ from $E(X|Y,Z)$, we would have to marginalize out $z$ using the conditional pdf of $Z$ given $Y$ as in the following, but we cannot write $E_{Z|Y}$:

$$\begin{split}\int_{-\infty}^\infty \left[\int_{-\infty}^\infty xg(x|y,z)dx\right]f(z|y)dz&=\int_{-\infty}^\infty \int_{-\infty}^\infty x g(x,z|y)dzdx\\ &=\int_{-\infty}^\infty xf(x|y)dx\\ &=E(X|Y)\end{split}$$

(For the discrete case, replace all the integrals with summations.)