maths stats - conditional density function

• Mar 24th 2009, 07:41 PM
continously confused
maths stats - conditional density function
I'm just very confused about conditional density function. like the question is to show that Ey[E(X|Y)] = E(X)

x=0 x=1 x=2 x=3
y = 0 o.o4 o.o5 o.o6 o.o7
y=1 o.o6 o.o8 o.o7 o.o9
y=2 o.1 o.11 o.13 o.14

well i think that E(X) is
0x.04 + 0x.06 + 0x.1 + 1x.05 + 1x.08 + 1x.11 + 2x.06 + 2x.07 + 2x.13 + 3x.07 + 3x.09 + 3x.14 = 1.66

and that E(X|Y) = P(x,y)/P(y)

but the thing is that i dont know how to calculate P(x,y). Can someone explain it to me please?
• Mar 24th 2009, 10:29 PM
matheagle
Quote:

Originally Posted by continously confused
I'm just very confused about conditional density function. like the question is to show that Ey[E(X|Y)] = E(X)

x=0 x=1 x=2 x=3
y = 0 o.o4 o.o5 o.o6 o.o7
y=1 o.o6 o.o8 o.o7 o.o9
y=2 o.1 o.11 o.13 o.14

well i think that E(X) is
0x.04 + 0x.06 + 0x.1 + 1x.05 + 1x.08 + 1x.11 + 2x.06 + 2x.07 + 2x.13 + 3x.07 + 3x.09 + 3x.14 = 1.66

and that E(X|Y) = P(x,y)/P(y) this is p(x|y) not E(X|Y)

but the thing is that i dont know how to calculate P(x,y). Can someone explain it to me please?

Is that p(x,y)?
• Mar 24th 2009, 11:50 PM
continously confused
yeahh it is, but the thing is i really dont understand what my p(x,y) is supposed to be.. like is it just one number? like the row totals or something?

Quote:

Originally Posted by matheagle
and that E(X|Y) = P(x,y)/P(y) this is p(x|y) not E(X|Y)

ohhh and umm im really dumb, so what is the difference between p(x|y) and E(X|Y)? what is it meant to be? thanks
• Mar 25th 2009, 12:13 AM
matheagle
SO, that is p(x,y). For example P(X=0,Y=0)=.04....
P(X=0|Y=0)=P(X=0,Y=0)/P(Y=0).

Y can be 0,1,2 so there are 3 values for E(X|Y=y), depending on y

$E(X|Y=0)=\sum_{x=0}^3 xP(X=x|Y=0)$
• Mar 25th 2009, 12:28 AM
continously confused
ahhh icic thank you. :]. but how do i show that Ey[E(X|Y)] = E(X)?
do i just do:

$E(X|Y=0)=\sum_{x=0}^3 xP(X=x|Y=0)$
$E(X|Y=1)=\sum_{x=0}^3 xP(X=x|Y=1)$
$E(X|Y=2)=\sum_{x=0}^3 xP(X=x|Y=2)$

• Mar 25th 2009, 12:35 AM
matheagle
$E(X)=\sum_x\sum_y xp(x,y)$

YOU need to be careful with that y in

$E(E(X|Y))=\sum_y E(X|Y=y))P(Y=y)$

Just consider E(X|Y=y)) as g(y) and

$E(g(Y))=\sum_y g(y) P(Y=y)$
• Mar 25th 2009, 12:47 AM
continously confused
ahhh okies, thank you!! (Nod)