# Multivariate Normal : expectation of X given Y is doubly-truncated

Let $$(X, Y)$$ be distributed as a multivariate normal with parameters

$$\mu = \begin{bmatrix} \mu_X \\ \mu_Y \end{bmatrix} \qquad \Sigma = \begin{bmatrix} \sigma_X^2 & \sigma_{XY} \\ \sigma_{XY} & \sigma_Y^2 \end{bmatrix}.$$

I would like to calculate $$E(X | y_1 < Y < y_2)$$, where $$y_1$$ and $$y_2$$ are constants.

From Wikipedia, I have managed to work out that $$E(X | Y > y_1) = \mu_X + \frac{\sigma_{XY}}{\sigma_Y} \left[\frac{\phi\left(\frac{y_1 - \mu_y}{\sigma_Y}\right)}{1 - \Phi\left(\frac{y_1 - \mu_y}{\sigma_Y}\right)}\right]\\ E(X | Y < y_2) = \mu_X - \frac{\sigma_{XY}}{\sigma_Y} \left[\frac{\phi\left(\frac{y_2 - \mu_y}{\sigma_Y}\right)}{\Phi\left(\frac{y_2 - \mu_y}{\sigma_Y}\right)}\right] ,$$ where $$\phi(\cdot)$$ and $$\Phi(\cdot)$$ are, respectively, the p.d.f. and the c.d.f. of the Normal distribution. I could not figure out how to calculate $$E(X | y_1 < Y < y_2)$$, though.

I have searched for an answer in similar posts from the Stack Exchange network, but I couldn't get a clue from them that would solve this issue. For the record, here are some of them:

• – StubbornAtom Jan 3 '19 at 10:49
• @StubbornAtom, thank you. I am studying the answers there and will post one here (since my question is different and the solution to it is but a step used in the answers posted there) ASAP. – Waldir Leoncio Jan 3 '19 at 11:27

you should use the same approach in point 3. the conditional expectation $$E(X|Y)=\mu_X+\sigma_{XY}\frac{Y-\mu_Y}{\sigma_Y^2}$$ Then take the expectation of the RHS of this expression given $$y_1. The only random variable is $$Y$$ and this has conditional expectation of $$E(Y|y_1 Plugging this in gives you $$E(X|y_1
this also contains your two answers as special cases $$y_1\to-\infty$$ and $$y_2\to\infty$$