If I already get the $E(X|Y)=y$, how could I derive $E(XY|Y)$ from $E(X|Y)$?
Is $E(XY|Y)$ = $yE(X|Y)=y^2$?
And then $E(XY)=E(E(XY|Y))$ How could I use the $E(XY|Y)$ to get the $E(XY)$?
Thanks~
If I already get the $E(X|Y)=y$, how could I derive $E(XY|Y)$ from $E(X|Y)$?
Is $E(XY|Y)$ = $yE(X|Y)=y^2$?
And then $E(XY)=E(E(XY|Y))$ How could I use the $E(XY|Y)$ to get the $E(XY)$?
Thanks~
On
$\mathsf E(X\mid Y)$ is the expected value of $X$ when conditioned by $Y$. (Often also expressed as "when measured against $Y$".) This should be a random variable; unless $X$ is independent of $Y$.
$\mathsf E(X\mid Y)$ is defined as some random variable such that the tower property holds $\mathsf E(\mathsf E(X\mid Y)) = \mathsf E(X)$
Thus if $y$ is a constant value, then $~\mathsf E(X\mid Y)=y~$ would indicate that $X$ is independent of $Y$. Otherwise $y$ should be dependent on $Y$ in some manner. (Notice the case-sensitivity. $Y$ and $y$ usually don't represent the same concept. Be very careful of your capitalisations.)
In any case, $~\mathsf E(XY\mid Y) ~=~ Y~\mathsf E(X\mid Y)~$ because $Y$ is relatively constant when measured against itself.
So if $~\mathsf E(X\mid Y)=y~$, then you have $~\mathsf E(XY\mid Y) = y~Y~$ .
On
First, $E[XY|Y]=E[X|Y]Y=yY$. This is because once you condition on $Y$, the variable can be treated as "fixed" or "constant" with respect to that expectation.
Then, $E[XY]=E[E[XY|Y]]=E[yY]$ by using the law of total expectation. Since you have mentioned that $y$ is a constant (that does not depend on the value of $Y$) then this is simply $E[XY]=yE[Y]$.
Caution: If what you mean is that $E[X|Y=y]=y$, then $E[XY|Y=y]=y^2$. Then, $E[XY]=E[E[XY|Y]]=E[Y^2]$.
Don't you have $$ \mathbb{E}[XY|Y=y] = Y\mathbb{E}[X|Y=y]? $$