If $X \sim N\left(\mu_x,\sigma^{2}_x\right)$ and $Y \sim N\left(\mu_y,\sigma^{2}_y\right) $ than what is $Y \mid X=x$?

94 Views Asked by At

Suppose $X \sim N\left(\mu_x,\sigma^{2}_x\right)$ and $Y \sim N\left(\mu_y,\sigma^{2}_y\right)$ then $Y \mid X=x\sim N\left(\mu_{y}+\rho\frac{\sigma_{y}}{\sigma_{x}} (x-\mu_x), \sigma_{y}^2\left(1-\rho^2\right)\right)$.

My question is:

  • How to show that $Y \mid X=x$ is also Normal distributed
  • How to show the joint PDF of $Y \mid X=x$ with using the formula $f_{Y \mid X=x}(y):=\frac{f(x, y)}{\int_{-\infty}^{\infty} f(x, t) d t}$.
1

There are 1 best solutions below

5
On

If the joint distribution of $$ and $$ is a bivariate normal with mean $\mu := (\mu_{x},\mu_{y})^{T}$ and covariance matrix $\Sigma := \big(\begin{smallmatrix} \sigma_{x}^{2} & \rho \sigma_{x} \sigma_{y}\\ \rho \sigma_{x} \sigma_{y} & \sigma_{y}^{2} \end{smallmatrix}\big)$ then the problem can be solved by some rather straightforward but tedious calculations. For $f(x,y)$ we use the density of the Multivariate normal distribution (link). First we calculate the inverse of $\Sigma$ since its a $2 \times 2$ matrix this can be done easily. We find, $$ \Sigma^{-1}= \frac{1}{(1-\rho^{2})\sigma_{x}^{2}\sigma_{y}^{2}}\begin{pmatrix} \sigma_{y}^{2} & -\rho \sigma_{x} \sigma_{y}\\ -\rho \sigma_{x} \sigma_{y} & \sigma_{x}^{2} \end{pmatrix}.$$ Then using the joint density we have, $$ f(x,y) = \frac{1}{\sqrt{(2\pi)^{2}(1-\rho^{2})\sigma_{x}^{2}\sigma_{y}^{2}}}\exp{\left(-\frac{1}{2}\begin{pmatrix} x - \mu_{x} \\ y - \mu_{y} \end{pmatrix}^{T}\Sigma^{-1}\begin{pmatrix} x - \mu_{x} \\ y - \mu_{y} \end{pmatrix}\right)}.$$ We now solve the $$ \begin{pmatrix} x - \mu_{x} \\ y - \mu_{y} \end{pmatrix}^{T}\Sigma^{-1}\begin{pmatrix} x - \mu_{x} \\ y - \mu_{y} \end{pmatrix} = \frac{\sigma_{y}^{2}(x-\mu_{x})^{2}-2\rho\sigma_{x}\sigma_{y}(x-\mu_{x})(y-\mu_{y})+\sigma_{x}^{2}(y-\mu_{y})^{2}}{(1-\rho^{2})\sigma_{x}^{2}\sigma_{y}^{2}}$$

Factoring out everything that does not depend on $y$ and doing quadratic expansion yields
\begin{align*} \int_{-\infty}^{-\infty}f(x,t)dt &= \frac{1}{\sqrt{2\pi\sigma_{x}}}\exp{-\frac{1}{2}\frac{\sigma_{y}^{2}(x-\mu_{x})^{2}+2\rho\sigma_{x}\sigma_{y}\mu_{y}-\mu_{y}^{2}+2\mu_{y}\rho\sigma_{x}\sigma_{y}(x-\mu_{x})-\rho^{2}\sigma_{y}^{2}(x-\mu_{x})^{2}}{(1-\rho^{2})\sigma_{x}^{2}\sigma_{y}^{2}}} \\ & \left( \frac{1}{\sqrt{2\pi(1-\rho^{2})\sigma_{y}^{2}}}\int_{-\infty}^{-\infty} \exp{-\frac{1}{2}\frac{\left(t - \mu_{y} -\rho \frac{\sigma_{y}}{\sigma{x}}(x-\mu_{x}) \right)^{2}}{(1-\rho^{2})\sigma_{y}^{2}}}dt\right) \\ &= \frac{1}{\sqrt{2\pi\sigma_{x}}}\exp{-\frac{1}{2}\frac{\sigma_{y}^{2}(x-\mu_{x})^{2}+2\rho\sigma_{x}\sigma_{y}\mu_{y}-\mu_{y}^{2}+2\mu_{y}\rho\sigma_{x}\sigma_{y}(x-\mu_{x})-\rho^{2}\sigma_{y}^{2}(x-\mu_{x})^{2}}{(1-\rho^{2})\sigma_{x}^{2}\sigma_{y}^{2}}}. \end{align*} Now we can plug this into the formula $f_{Y \mid X=x}(y):=\frac{f(x, y)}{\int_{-\infty}^{\infty} f(x, t) d t}.$ We find, \begin{align*} f_{Y \mid X=x}(y)&= \frac{f(x, y)}{\int_{-\infty}^{\infty} f(x, t) d t} \\ &= \frac{\frac{1}{\sqrt{(2\pi)^{2}(1-\rho^{2})\sigma_{x}^{2}\sigma_{y}^{2}}}\exp{-\frac{1}{2}}\frac{\sigma_{y}^{2}(x-\mu_{x})^{2}-2\rho\sigma_{x}\sigma_{y}(x-\mu_{x})(y-\mu_{y})+\sigma_{x}^{2}(y-\mu_{y})^{2}}{(1-\rho^{2})\sigma_{x}^{2}\sigma_{y}^{2}}}{\frac{1}{\sqrt{2\pi\sigma_{x}}}\exp{-\frac{1}{2}\frac{\sigma_{y}^{2}(x-\mu_{x})^{2}+2\rho\sigma_{x}\sigma_{y}\mu_{y}-\mu_{y}^{2}+2\mu_{y}\rho\sigma_{x}\sigma_{y}(x-\mu_{x})-\rho^{2}\sigma_{y}^{2}(x-\mu_{x})^{2}}{(1-\rho^{2})\sigma_{x}^{2}\sigma_{y}^{2}}}} \\ &= \frac{1}{\sqrt{2\pi(1-\rho^{2})\sigma_{y}^{2}}}\exp{-\frac{1}{2}\frac{y^2-2y\mu_{y}+2y\rho \frac{\sigma_{y}}{\sigma_{x}}(x-\mu_{x})+\mu_{y}^{2}-2\mu_{y}\rho \frac{\sigma_{y}}{\sigma_{x}}(x-\mu_{x})+\rho^{2} \frac{\sigma^{2}_{y}}{\sigma^{2}_{x}}(x-\mu_{x})^{2}}{(1-\rho^{2})^{2}\sigma_{y}^{2}}} \\ &= \frac{1}{\sqrt{2\pi(1-\rho^{2})\sigma_{y}^{2}}}\exp{-\frac{1}{2}\frac{\left(y-\mu_{y}+\rho \frac{\sigma_{y}}{\sigma_{x}}(x-\mu_{x})\right)^{2}}{(1-\rho^{2})^{2}\sigma_{y}^{2}}} \\ &= \end{align*} Where the last step is the density of a normally distributed one dimensional random variable with $$ Y \mid X=x \sim N\left(\mu_y+\rho \frac{\sigma_y}{\sigma_x}\left(x-\mu_x\right), \sigma_y^2\left(1-\rho^2\right)\right).$$