Яка різниця між


18

Як правило, яка різниця між E(X|Y) і E(X|Y=y) ?

Попереднє - функція y а остання - функція x ? Це так заплутано ..


Хммм ... Останнє не повинно бути функцією x, а числа! Я помиляюся?
— Девід

Відповіді:


23

Грубо кажучи, різниця між E(X∣Y) і E(X∣Y=y) полягає в тому, що перша є випадковою змінною, тоді як остання є (в деякому сенсі) реалізацією E(X∣Y) . Наприклад, якщо

(X,Y)∼N(0,(1ρρ1))
то E(X∣Y)це випадкова величина І навпаки, як тільки спостерігається Y = y , ми з більшою ймовірністю будемо цікавити величину E ( X ∣ Y = y ) = ρ y, яка є скалярною.
E(X∣Y)=ρY.
Y=yE(X∣Y=y)=ρy

Можливо, це здається непотрібним ускладненням, але відносно як випадкової змінної саме по собі є те, що робить такі речі, як вежа-закон E ( X ) = E [ E ( X ∣ Y ) ] має сенс - річ на внутрішній стороні брекетів випадкова, тому ми можемо запитати, яке її очікування, тоді як про E ( X ∣ Y = y ) немає нічого випадкового . У більшості випадків ми можемо сподіватися обчислити E ( X ∣ Y =E(X∣Y)E(X)=E[E(X∣Y)]E(X∣Y=y)

E(X∣Y=y)=∫xfX∣Y(x∣y) dx

а потім отримаємо , "включивши" випадкову змінну Y замість y в результуючому виразі. Як натякнуто в попередньому коментарі, є трохи тонкощів, які можуть повстати щодо того, як ці речі суворо визначені та пов’язують їх відповідним чином. Це, як правило, відбувається з умовною ймовірністю через деякі технічні проблеми, що лежать в основі теорії.E(X∣Y)Yy


8

Припустимо, що X і Y - випадкові величини.

Нехай y0 - фіксоване дійсне число, скажімо, y0=1 . Тоді E[X∣Y=y0]=E[X∣Y=1] є число : це умовне очікуване значення з X за умови , що Y має значення 1 . Тепер зверніть увагу на деяке інше фіксоване дійсне число y1 , скажімо, y1=1.5 , E[X∣Y=y1]=E[X∣Y=1.5] було б умовним очікуваним значенням X заданимY=1.5 (дійсне число). Немає підстав вважати, щоE[X∣Y=1.5] іE[X∣Y=1] мають однакове значення. Таким чином, ми можемо також розглянутиE[X∣Y=y] як areal-valued function g(y) that maps real numbers y to real numbers E[X∣Y=y]. Note that the statement in the OP's question that E[X∣Y=y] is a function of x is incorrect: E[X∣Y=y] is a real-valued function of y.

On the other hand, E[X∣Y] is a random variable Z which happens to be a function of the random variable Y. Now, whenever we write Z=h(Y), what we mean is that whenever the random variable Y happens to have value y, the random variable Z has value h(y). Whenever Y takes on value y, the random variable Z=E[X∣Y] takes on value E[X∣Y=y]=g(y). Thus, E[X∣Y] is just another name for the random variable Z=g(Y). Note that E[X∣Y] is a function of Y (not y as in the statement of the OP's question).

As a a simple illustrative example, suppose that X and Y are discrete random variables with joint distribution

P(X=0,Y=0)=0.1,  P(X=0,Y=1)=0.2,P(X=1,Y=0)=0.3,  P(X=1,Y=1)=0.4.
Note that X and Y are (dependent) Bernoulli random variables with parameters 0.7 and 0.6 respectively, and so E[X]=0.7 and E[Y]=0.6. Now, note that conditioned on Y=0, X is a Bernoulli random variable with parameter 0.75 while conditioned on Y=1, X is a Bernoulli random variable with parameter 23. If you cannot see why this is so immediately, just work out the details: for example
P(X=1∣Y=0)=P(X=1,Y=0)P(Y=0)=0.30.4=34,P(X=0∣Y=0)=P(X=0,Y=0)P(Y=0)=0.10.4=14,
and similarly for P(X=1∣Y=1) and P(X=0∣Y=1). Hence, we have that
E[X∣Y=0]=34,E[X∣Y=1]=23.
Thus, E[X∣Y=y]=g(y) where g(y) is a real-valued function enjoying the properties:
g(0)=34,g(1)=23.

On the other hand, E[X∣Y]=g(Y) is a random variable that takes on values 34 and 23 with probabilities 0.4=P(Y=0) and 0.6=P(Y=1) respectively. Note that E[X∣Y] is a discrete random variable but is not a Bernoulli random variable.

As a final touch, note that

E[Z]=E[E[X∣Y]]=E[g(Y)]=0.4×34+0.6×23=0.7=E[X].
That is, the expected value of this function of Y, which we computed using only the marginal distribution of Y, happens to have the same numerical value as E[X] !! This is an illustration of a more general result that many people believe is a LIE:
E[E[X∣Y]]=E[X].

Sorry, that's just a small joke. LIE is an acronym for Law of Iterated Expectation which is a perfectly valid result that everyone believes is the truth.


3

E(X|Y) is the expectation of a random variable: the expectation of X conditional on Y. E(X|Y=y), on the other hand, is a particular value: the expected value of X when Y=y.

Think of it this way: let X represent the caloric intake and Y represent height. E(X|Y) is then the caloric intake, conditional on height - and in this case, E(X|Y=y) represents our best guess at the caloric intake (X) when a person has a certain height Y=y, say, 180 centimeters.


4
I believe your first sentence should replace "distribution" with "expectation" (twice).
— Glen_b -Reinstate Monica

4
E(X∣Y) isn't the distribution of X given Y; this would be more commonly denotes by the conditional density fX∣Y(x∣y) or conditional distribution function. E(X∣Y) is the conditional expectation of X given Y, which is a Y-measurable random variable. E(X∣Y=y) might be thought of as the realization of the random variable E(X∣Y) when Y=y is observed (but there is the possibility for measure-theoretic subtlety to creep in).
— guy

1
@guy Your explanation is the first accurate answer yet provided (out of three offered so far). Would you consider posting it as an answer?
— whuber

@whuber I would but I'm not sure how to strike the balance between accuracy and making the answer suitably useful to OP and I'm paranoid about getting tripped up on technicalities :)
— guy

@Guy I think you have already done a good job with the technicalities. Since you are sensitive about communicating well with the OP (which is great!), consider offering a simple example to illustrate--maybe just a joint distribution with binary marginals.
— whuber

1

E(X|Y) is expected value of values of X given values of Y E(X|Y=y) is expected value of X given the value of Y is y

Generally P(X|Y) is probability of values X given values Y, but you can get more precise and say P(X=x|Y=y), i.e. probability of value x from all X's given the y'th value of Y's. The difference is that in the first case it is about "values of" and in the second you consider a certain value.

You could find the diagram below helpful.

Bayes theorem diagram form Wikipedia


This answer discusses probability, while the question asks about expectation. What is the connection?
— whuber
Використовуючи наш веб-сайт, ви визнаєте, що прочитали та зрозуміли наші Політику щодо файлів cookie та Політику конфіденційності.
Licensed under cc by-sa 3.0 with attribution required.