# Thread: Help with conditional probability of joint density functions.

1. ## Help with conditional probability of joint density functions.

Let X and Y be continuous random variables with joint density function
$f(x,y)=\left\{\begin{array}{lr}(24xy)&0< x< 1;0< y<1-x\\0&otherwise\end{array}\right.$

How would you determine the correlation coefficient, say p, and then calculate the conditional probability of P [ Y < X | X= .5 ]

thank you for your help times infinity!

2. $Cov(X,Y) = E(XY) - E(X)E(Y)$

$\rho = \frac{Cov(X,Y)}{\sigma_X\sigma_Y}$

Figure out the expectation the joint distribution.

$E(XY) = \int_0^1\int_0^{1-x}xyf(x,y)dydx$

Figure out the conditional distributions of X and Y.

$f_X(x) = \int_0^{1-x}f(x,y)dy$

$f_Y(y) = \int_0^1 f(x,y)dx$

Figure out the expectation of X and Y.

$E(X) = \int_0^1 xf_X(x)dx$

$E(Y) = \int_0^{1-x} yf_Y(y)dy$

Figure out the variance of X and Y.

$\sigma_X^2 = E(X^2) - [E(X)]^2$

$\sigma_Y^2 = E(Y^2) - [E(X)]^2$

Plug in the appropriate functions and now you have correlation.

3. Originally Posted by BERRY
$Cov(X,Y) = E(XY) - E(X)E(Y)$

$\rho = \frac{Cov(X,Y)}{\sigma_X\sigma_Y}$

Figure out the expectation the joint distribution.

$E(XY) = \int_0^1\int_0^{1-x}xyf(x,y)dydx$

Figure out the conditional distributions of X and Y.

$f_X(x) = \int_0^{1-x}f(x,y)dy$

$f_Y(y) = \int_0^1 f(x,y)dx$

Figure out the expectation of X and Y.

$E(X) = \int_0^1 xf_X(x)dx$

$E(Y) = \int_0^{1-x} yf_Y(y)dy$

Figure out the variance of X and Y.

$\sigma_X^2 = E(X^2) - [E(X)]^2$

$\sigma_Y^2 = E(Y^2) - [E(X)]^2$

Plug in the appropriate functions and now you have correlation.
one question...

When you figure out the conditional distributions of X and Y.

should it be

$f_Y(y) = \int_0^{1-x}f(x,y)dx$
not

$f_Y(y) = \int_0^1 f(x,y)dx$ ??

and also,
when you figure out the variance of X and Y.

$\sigma_Y^2 = E(Y^2) - [E(Y)]^2$
not
$\sigma_Y^2 = E(Y^2) - [E(X)]^2$ right?

4. Originally Posted by Statsnoob2718
one question...

When you figure out the conditional distributions of X and Y.

should it be

$f_Y(y) = \int_0^{1-x}f(x,y)dx$
not

$f_Y(y) = \int_0^1 f(x,y)dx$ ??

and also,
when you figure out the variance of X and Y.

$\sigma_Y^2 = E(Y^2) - [E(Y)]^2$
not
$\sigma_Y^2 = E(Y^2) - [E(X)]^2$ right?
For the variance of Y, I mistyped it. You're correct.

For the conditional of Y, you integrate over x (thus the dx) and x ranges from 0 to 1 so the original is correct.

5. Oh, cool dude, yeah I just drew a picture of the bounds to confirm, you're right about the limits. Great work!

6. Originally Posted by Statsnoob2718
one question...

$f_Y(y) = \int_0^{1-x}f(x,y)dx$
not

$f_Y(y) = \int_0^1 f(x,y)dx$ ??

Both are wrong

A function of y cannot have x in it.
The correct marginal is

$f_Y(y) = \int_0^{1-y}f(x,y)dx$

just like

$f_X(x) = \int_0^{1-x}f(x,y)dy$

7. Likewise the E(Y) is wrong here

$E(X) = \int_0^1 xf_X(x)dx$

$E(Y) = \int_0^{1-x} yf_Y(y)dy$.
$E(Y) = \int_0^{1} yf_Y(y)dy$

IF you want to obtain the marginal density.
But it's better to look at this two dimensionally...

$E(Y) = \int_0^{1} yf_Y(y)dy =\int_0^{1} y\int_0^{1-y}f(x,y)dxdy=\int_0^{1} \int_0^{1-y}yf(x,y)dxdy$

Because you have the choice of which variable you can integrate first

$E(Y) = \int_0^{1} \int_0^{1-x}yf(x,y)dydx$