# Conditional Density of Random Variables

Hi all,

I read recently that for any three continuous random variables, X,Y and Z, the conditional densities are related by the following formula:

$p(x|y) = \int g(x| z) h(z | y ) dz$

where $p(x|y)$ is conditional density of X given Y = y and so on.

I have never come across this relation before. It seems similar to Chapman-Kolmogorov equation but the paper I found this relation in claims it is true for any 3 continuous random variables. Can anyone provide a proof of the above relation please?

Thanks.

-

This is not true in general since you would need the additional condition $g(x|z)=p(x|y,z)$ on the conditional densities for that formula to hold true. As a counter-example, consider $y,z,\epsilon$ all independent standard normal and let $x=y+z+\epsilon$. Then $x|y$ is a normal $N(y,2)$ (conditional expectation $y$ and variance 2). However, if you apply the formula you gave, that would yield a normal $N(0,3)$ for $x|y$ which is not correct (to verify this integrate $z$ out from the product of an $N(z,2)$ and an $N(0,1)$ for $x|z$ and $z|y$ respectively).