$E(X)$ versus $E(X|Y)$

107 Views Asked by At

Why is $E(X)$ considered a constant but $E(X|Y)$ considered a random variable? Seems like confusing notation since I'd assume the latter is a fixed constant "the expected value of random variable $X$ given the value of random variable $Y$".

4

There are 4 best solutions below

0
On BEST ANSWER

Yes, the notation is confusing: $E(X)$ is a constant, but $E(X\mid Y)$ is a random thing.

If you haven't gotten to advanced (measure-theoretic) probability yet, then $E(X\mid Y)$ is usually introduced by considering $E(X\mid Y=y)$, the conditional expectation of $X$ given that $Y=y$. Now think of this as a function of $y$, i.e. it's a function $h(y)$ mapping the value $y$ to the value $E(X\mid Y=y)$. You should then regard the random thing $E(X\mid Y)$ as $h(Y)$, the result of applying the function $h$ to the random variable $Y$. $E(X\mid Y)$ is then a random variable whose value depends only on the value of $Y$.

5
On

I'm not familiar with the measure-theoretic approach to conditional expectation and would appreciate it if someone could correct my response here (or even better, post a dumbed-down explanation of how conditional expectation is defined). But I suppose one way you could look at this is by noticing that - for example, if $X$ and $Y$ are continuous - $$\mathbb{E}[X \mid Y = y] = \int_{-\infty}^{\infty}xf_{X \mid Y}(x \mid y)\text{ d}x\text{.}$$ Integrating the above only integrates with respect to the values of $X$, and still leaves values of $Y$ hanging, from which we may take expectations - so we are still left with a random variable.

5
On

This is a bit unnecessarily elaborate machinery, but if you want, you can view $E[X]$ as $E[X \mid \{ \emptyset,\Omega \}]$. Thus, $E[X]$ is measurable with respect to $\{ \emptyset,\Omega \}$. But the only such functions are constant (exercise). It is more convenient to view constant functions as just being literally equal to their value than to view them as constant functions.

By contrast, typically $E[X \mid Y]$ depends on the value of $Y$, so it is still random.

0
On

I'd assume the latter is a fixed constant "the expected value of random variable $X$ given the value of random variable $Y$".

$\mathsf E(X\mid Y)$ is rather: "the expected value of random variable $X$ for any given value of random variable $Y$."   You don't know what value you might be given, so how can this be a fixed constant?†   The expectation thus must be a random variable determined by $Y$.   That is to say, a function of $Y$.

$\mathsf E(X)$ is simply the expectation of $X$; it is not contingent on any particular outcomes.   It can only be a constant value.


(† $\mathsf E(X\mid Y)$ can only be a constant-valued function when $X$ and $Y$ are uncorrelated .)