Open main menu
Home
Random
Recent changes
Special pages
Community portal
Preferences
About Wikipedia
Disclaimers
Incubator escapee wiki
Search
User menu
Talk
Dark mode
Contributions
Create account
Log in
Editing
Conditional expectation
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
Anti-spam check. Do
not
fill this in!
{{short description|Expected value of a random variable given that certain conditions are known to occur}} {{More footnotes needed|date=September 2020}} In [[probability theory]], the '''conditional expectation''', '''conditional expected value''', or '''conditional mean''' of a [[random variable]] is its [[expected value]] evaluated with respect to the [[conditional probability distribution]]. If the random variable can take on only a finite number of values, the "conditions" are that the variable can only take on a subset of those values. More formally, in the case when the random variable is defined over a discrete [[probability space]], the "conditions" are a [[partition of a set|partition]] of this probability space. Depending on the context, the conditional expectation can be either a random variable or a function. The random variable is denoted <math>E(X\mid Y)</math> analogously to [[conditional probability]]. The function form is either denoted <math>E(X\mid Y=y)</math> or a separate function symbol such as <math>f(y)</math> is introduced with the meaning <math>E(X\mid Y) = f(Y)</math>. ==Examples== === Example 1: Dice rolling === Consider the roll of a fair die and let ''A'' = 1 if the number is even (i.e., 2, 4, or 6) and ''A'' = 0 otherwise. Furthermore, let ''B'' = 1 if the number is prime (i.e., 2, 3, or 5) and ''B'' = 0 otherwise. {| class="wikitable" |- ! !! 1 !! 2 !! 3 !! 4 !! 5 !! 6 |- | A || 0 || 1 || 0 || 1 || 0 || 1 |- | B || 0 || 1 || 1 || 0 || 1 || 0 |} The unconditional expectation of A is <math>E[A] = (0+1+0+1+0+1)/6 = 1/2</math>, but the expectation of A ''conditional'' on ''B'' = 1 (i.e., conditional on the die roll being 2, 3, or 5) is <math>E[A\mid B=1]=(1+0+0)/3=1/3</math>, and the expectation of A conditional on ''B'' = 0 (i.e., conditional on the die roll being 1, 4, or 6) is <math>E[A\mid B=0]=(0+1+1)/3=2/3</math>. Likewise, the expectation of B conditional on A = 1 is <math>E[B\mid A=1]= (1+0+0)/3=1/3</math>, and the expectation of ''B'' conditional on ''A'' = 0 is <math>E[B\mid A=0]=(0+1+1)/3=2/3</math>. === Example 2: Rainfall data === Suppose we have daily rainfall data (mm of rain each day) collected by a weather station on every day of the ten-year (3652-day) period from January 1, 1990, to December 31, 1999. The unconditional expectation of rainfall for an unspecified day is the average of the rainfall amounts for those 3652 days. The ''conditional'' expectation of rainfall for an otherwise unspecified day known to be (conditional on being) in the month of March, is the average of daily rainfall over all 310 days of the ten–year period that fall in March. Similarly, the conditional expectation of rainfall conditional on days dated March 2 is the average of the rainfall amounts that occurred on the ten days with that specific date. == History == The related concept of [[conditional probability]] dates back at least to [[Pierre-Simon Laplace|Laplace]], who calculated conditional distributions. It was [[Andrey Nikolaevich Kolmogorov|Andrey Kolmogorov]] who, in 1933, formalized it using the [[Radon–Nikodym theorem]].<ref name=kol1933 /> In works of [[Paul Halmos]]<ref name=halmos1950 /> and [[Joseph L. Doob]]<ref name=doob1953 /> from 1953, conditional expectation was generalized to its modern definition using [[sigma-algebra|sub-''σ''-algebras]].<ref>Olav Kallenberg: ''Foundations of Modern Probability.'' 2. edition. Springer, New York 2002, {{ISBN|0-387-95313-2}}, p. 573.</ref> == Definitions == === Conditioning on an event === If {{mvar|A}} is an event in <math>\mathcal{F}</math> with nonzero probability, and {{mvar|X}} is a [[discrete random variable]], the conditional expectation of {{mvar|X}} given {{mvar|A}} is :<math> \begin{aligned} \operatorname{E} (X \mid A) &= \sum_x x P(X = x \mid A) \\ & =\sum_x x \frac{P(\{X = x\} \cap A)}{P(A)} \end{aligned} </math> where the sum is taken over all possible outcomes of {{mvar|X}}. If <math>P(A) = 0</math>, the conditional expectation is undefined due to the division by zero. === Discrete random variables === If {{mvar|X}} and {{mvar|Y}} are [[discrete random variable]]s, the conditional expectation of {{mvar|X}} given {{mvar|Y}} is :<math> \begin{aligned} \operatorname{E} (X \mid Y=y) &= \sum_x x P(X = x \mid Y = y) \\ &= \sum_x x \frac{P(X = x, Y = y)}{P(Y=y)} \end{aligned} </math> where <math>P(X = x, Y = y)</math> is the [[joint probability mass function]] of {{mvar|X}} and {{mvar|Y}}. The sum is taken over all possible outcomes of {{mvar|X}}. As above, the expression is undefined if <math>P(Y=y) = 0</math>. Conditioning on a discrete random variable is the same as conditioning on the corresponding event: :<math>\operatorname{E} (X \mid Y=y) = \operatorname{E} (X \mid A)</math> where {{mvar|A}} is the set <math>\{ Y = y \}</math>. === Continuous random variables === Let <math>X</math> and <math>Y</math> be [[continuous random variable]]s with joint density <math>f_{X,Y}(x,y),</math> <math>Y</math>'s density <math>f_{Y}(y),</math> and conditional density <math>\textstyle f_{X\mid Y}(x\mid y) = \frac{ f_{X,Y}(x,y) }{f_{Y}(y)}</math> of <math>X</math> given the event <math>Y=y.</math> The conditional expectation of <math>X</math> given <math>Y=y</math> is :<math> \begin{aligned} \operatorname{E} (X \mid Y=y) &= \int_{-\infty}^\infty x f_{X\mid Y}(x\mid y) \, \mathrm{d}x \\ &= \frac{1}{f_Y(y)}\int_{-\infty}^\infty x f_{X,Y}(x,y) \, \mathrm{d}x. \end{aligned} </math> When the denominator is zero, the expression is undefined. Conditioning on a continuous random variable is not the same as conditioning on the event <math>\{ Y = y \}</math> as it was in the discrete case. For a discussion, see [[Conditional probability#Conditioning on an event of probability zero|Conditioning on an event of probability zero]]. Not respecting this distinction can lead to contradictory conclusions as illustrated by the [[Borel-Kolmogorov paradox]]. === L<sup>2</sup> random variables === All random variables in this section are assumed to be in <math>L^2</math>, that is [[square integrable]]. In its full generality, conditional expectation is developed without this assumption, see below under [[Conditional expectation#Conditional expectation with respect to a sub-''σ''-algebra|Conditional expectation with respect to a sub-''σ''-algebra]]. The <math>L^2</math> theory is, however, considered more intuitive<ref>{{cite web |title=probability - Intuition behind Conditional Expectation |url=https://math.stackexchange.com/a/23613/357269 |website=Mathematics Stack Exchange}}</ref> and admits [[Conditional expectation#Connections to regression|important generalizations]]. In the context of <math>L^2</math> random variables, conditional expectation is also called [[Regression analysis|regression]]. In what follows let <math>(\Omega, \mathcal{F}, P)</math> be a probability space, and <math>X: \Omega \to \mathbb{R}</math> in <math>L^2</math> with mean <math>\mu_X</math> and [[variance]] <math>\sigma_X^2</math>. The expectation <math>\mu_X</math> minimizes the [[mean squared error]]: :<math> \min_{x \in \mathbb{R}} \operatorname{E}\left((X - x)^2\right) = \operatorname{E}\left((X - \mu_X)^2\right) = \sigma_X^2. </math> The conditional expectation of {{mvar|X}} is defined analogously, except instead of a single number <math>\mu_X</math>, the result will be a function <math>e_X(y)</math>. Let <math>Y: \Omega \to \mathbb{R}^n</math> be a [[random vector]]. The conditional expectation <math>e_X: \mathbb{R}^n \to \mathbb{R}</math> is a measurable function such that :<math> \min_{g \text{ measurable }} \operatorname{E}\left((X - g(Y))^2\right) = \operatorname{E}\left((X - e_X(Y))^2\right). </math> Note that unlike <math>\mu_X</math>, the conditional expectation <math>e_X</math> is not generally unique: there may be multiple minimizers of the mean squared error. ==== Uniqueness ==== '''Example 1''': Consider the case where {{mvar|Y}} is the constant random variable that is always 1. Then the mean squared error is minimized by any function of the form :<math> e_X(y) = \begin{cases} \mu_X & \text{if } y = 1, \\ \text{any number} & \text{otherwise.} \end{cases} </math> '''Example 2''': Consider the case where {{mvar|Y}} is the 2-dimensional random vector <math>(X, 2X)</math>. Then clearly :<math>\operatorname{E}(X \mid Y) = X</math> but in terms of functions it can be expressed as <math>e_X(y_1, y_2) = 3y_1-y_2</math> or <math>e'_X(y_1, y_2) = y_2 - y_1</math> or infinitely many other ways. In the context of [[linear regression]], this lack of uniqueness is called [[multicollinearity]]. Conditional expectation is unique up to a set of measure zero in <math>\mathbb{R}^n</math>. The measure used is the [[pushforward measure]] induced by {{mvar|Y}}. In the first example, the pushforward measure is a [[Dirac distribution]] at 1. In the second it is concentrated on the "diagonal" <math>\{ y : y_2 = 2 y_1 \}</math>, so that any set not intersecting it has measure 0. ==== Existence ==== The existence of a minimizer for <math> \min_g \operatorname{E}\left((X - g(Y))^2\right)</math> is non-trivial. It can be shown that :<math> M := \{ g(Y) : g \text{ is measurable and }\operatorname{E}(g(Y)^2) < \infty \} = L^2(\Omega, \sigma(Y)) </math> is a closed subspace of the Hilbert space <math>L^2(\Omega)</math>.<ref>{{cite book |last1=Brockwell |first1=Peter J. |title=Time series : theory and methods |date=1991 |publisher=Springer-Verlag |location=New York |isbn=978-1-4419-0320-4 |edition=2nd}}</ref> By the [[Hilbert projection theorem]], the necessary and sufficient condition for <math>e_X</math> to be a minimizer is that for all <math>f(Y)</math> in {{mvar|M}} we have :<math> \langle X - e_X(Y), f(Y) \rangle = 0. </math> In words, this equation says that the [[residual (statistics)|residual]] <math>X - e_X(Y)</math> is orthogonal to the space {{mvar|M}} of all functions of {{mvar|Y}}. This orthogonality condition, applied to the [[indicator function]]s <math>f(Y) = 1_{Y \in H}</math>, is used below to extend conditional expectation to the case that {{mvar|X}} and {{mvar|Y}} are not necessarily in <math>L^2</math>. ==== Connections to regression ==== The conditional expectation is often approximated in [[applied mathematics]] and [[statistics]] due to the difficulties in analytically calculating it, and for interpolation.<ref>{{cite book |last1=Hastie |first1=Trevor |title=The elements of statistical learning : data mining, inference, and prediction |date=26 August 2009 |location=New York |isbn=978-0-387-84858-7 |edition=Second, corrected 7th printing |url=https://web.stanford.edu/~hastie/Papers/ESLII.pdf}}</ref> The Hilbert subspace :<math> M = \{ g(Y) : \operatorname{E}(g(Y)^2) < \infty \}</math> defined above is replaced with subsets thereof by restricting the functional form of {{mvar|g}}, rather than allowing any measurable function. Examples of this are [[Decision tree learning|decision tree regression]] when {{mvar|g}} is required to be a [[simple function]], [[linear regression]] when {{mvar|g}} is required to be [[affine transformation|affine]], etc. These generalizations of conditional expectation come at the cost of many of [[Conditional expectation#Basic properties|its properties]] no longer holding. For example, let {{mvar|M}} be the space of all linear functions of {{mvar|Y}} and let <math>\mathcal{E}_{M}</math> denote this generalized conditional expectation/<math>L^2</math> projection. If <math>M</math> does not contain the [[constant function]]s, the [[tower property]] <math> \operatorname{E}(\mathcal{E}_M(X)) = \operatorname{E}(X) </math> will not hold. An important special case is when {{mvar|X}} and {{mvar|Y}} are jointly normally distributed. In this case it can be shown that the conditional expectation is equivalent to linear regression: :<math> e_X(Y) = \alpha_0 + \sum_i \alpha_i Y_i</math> for coefficients <math>\{\alpha_i\}_{i = 0..n}</math> described in [[Multivariate normal distribution#Conditional distributions]]. === Conditional expectation with respect to a sub-''σ''-algebra === [[File:LokaleMittelwertbildung.svg|thumb|upright=1.5|'''Conditional expectation with respect to a ''σ''-algebra:''' in this example the probability space <math>(\Omega, \mathcal{F}, P)</math> is the [0,1] interval with the [[Lebesgue measure]]. We define the following ''σ''-algebras: <math>\mathcal{A} = \mathcal{F}</math>; <math>\mathcal{B}</math> is the ''σ''-algebra generated by the intervals with end-points 0, {{frac|1|4}}, {{frac|1|2}}, {{frac|3|4}}, 1; and <math>\mathcal{C}</math> is the ''σ''-algebra generated by the intervals with end-points 0, {{frac|1|2}}, 1. Here the conditional expectation is effectively the average over the minimal sets of the ''σ''-algebra.]] Consider the following: * <math>(\Omega, \mathcal{F}, P)</math> is a [[probability space]]. * <math>X\colon\Omega \to \mathbb{R}^n</math> is a [[random variable#Definition|random variable]] on that probability space with finite expectation. * <math>\mathcal{H} \subseteq \mathcal{F}</math> is a sub-[[sigma-algebra|''σ''-algebra]] of <math>\mathcal{F}</math>. Since <math>\mathcal{H}</math> is a sub <math>\sigma</math>-algebra of <math>\mathcal{F}</math>, the function <math>X\colon\Omega \to \mathbb{R}^n</math> is usually not <math>\mathcal{H}</math>-measurable, thus the existence of the integrals of the form <math display="inline">\int_H X \,dP|_\mathcal{H}</math>, where <math>H\in\mathcal{H}</math> and <math>P|_\mathcal{H}</math> is the restriction of <math>P</math> to <math>\mathcal{H}</math>, cannot be stated in general. However, the local averages <math display="inline">\int_H X\,dP</math> can be recovered in <math>(\Omega, \mathcal{H}, P|_\mathcal{H})</math> with the help of the conditional expectation. A '''conditional expectation''' of ''X'' given <math>\mathcal{H}</math>, denoted as <math>\operatorname{E}(X\mid\mathcal{H})</math>, is any <math>\mathcal{H}</math>-[[measurable function]] <math>\Omega \to \mathbb{R}^n</math> which satisfies: :<math> \int_H\operatorname{E}(X \mid \mathcal{H})\,\mathrm{d}P = \int_H X \,\mathrm{d}P</math> for each <math>H \in \mathcal{H}</math>.<ref name=billingsley1995/> As noted in the <math>L^2</math> discussion, this condition is equivalent to saying that the [[residual (statistics)|residual]] <math>X - \operatorname{E}(X \mid \mathcal{H})</math> is orthogonal to the indicator functions <math>1_H</math>: :<math> \langle X - \operatorname{E}(X \mid \mathcal{H}), 1_H \rangle = 0 </math> ==== Existence ==== The existence of <math>\operatorname{E}(X\mid\mathcal{H})</math> can be established by noting that <math display="inline">\mu^X\colon F \mapsto \int_F X \, \mathrm{d}P</math> for <math>F \in \mathcal{F}</math> is a finite measure on <math>(\Omega, \mathcal{F})</math> that is [[absolute continuity|absolutely continuous]] with respect to <math>P</math>. If <math>h</math> is the [[natural injection]] from <math>\mathcal{H}</math> to <math>\mathcal{F}</math>, then <math>\mu^X \circ h = \mu^X|_\mathcal{H}</math> is the restriction of <math>\mu^X</math> to <math>\mathcal{H}</math> and <math>P \circ h = P|_\mathcal{H}</math> is the restriction of <math>P</math> to <math>\mathcal{H}</math>. Furthermore, <math>\mu^X \circ h</math> is absolutely continuous with respect to <math>P \circ h</math>, because the condition :<math>P \circ h (H) = 0 \iff P(h(H)) = 0</math> implies :<math>\mu^X(h(H)) = 0 \iff \mu^X \circ h(H) = 0.</math> Thus, we have :<math>\operatorname{E}(X\mid\mathcal{H}) = \frac{\mathrm{d}\mu^X|_\mathcal{H}}{\mathrm{d}P|_\mathcal{H}} = \frac{\mathrm{d}(\mu^X \circ h)}{\mathrm{d}(P \circ h)},</math> where the derivatives are [[Radon–Nikodym theorem|Radon–Nikodym derivatives]] of measures. ==== Conditional expectation with respect to a random variable ==== Consider, in addition to the above, * A [[measurable space]] <math>(U, \Sigma)</math>, and * A random variable <math>Y\colon\Omega \to U</math>. The conditional expectation of {{mvar|X}} given {{mvar|Y}} is defined by applying the above construction on the [[Σ-algebra#σ-algebra generated by random variable or vector|''σ''-algebra generated by]] {{mvar|Y}}: :<math>\operatorname{E}[X\mid Y] := \operatorname{E}[X\mid\sigma(Y)]. </math> By the [[Doob–Dynkin lemma]], there exists a function <math>e_X \colon U \to \mathbb{R}^n</math> such that :<math>\operatorname{E}[X\mid Y] = e_X(Y). </math> ==== Discussion ==== * This is not a constructive definition; we are merely given the required property that a conditional expectation must satisfy. ** The definition of <math>\operatorname{E}(X \mid \mathcal{H})</math> may resemble that of <math>\operatorname{E}(X \mid H)</math> for an event <math>H</math> but these are very different objects. The former is a <math>\mathcal{H}</math>-measurable function <math>\Omega \to \mathbb{R}^n</math>, while the latter is an element of <math>\mathbb{R}^n</math> and <math>\operatorname{E}(X \mid H)\ P(H)= \int_H X \,\mathrm{d}P= \int_H \operatorname{E} (X\mid\mathcal{H})\,\mathrm{d}P</math> for <math>H\in\mathcal{H}</math>. ** Uniqueness can be shown to be [[almost surely|almost sure]]: that is, versions of the same conditional expectation will only differ on a [[null set|set of probability zero]]. *** Often, one would like to think of <math>\operatorname{E}(X \mid \mathcal{H})</math> as a measure on <math>\Omega</math> for fixed H. For example, it is extremely useful to claim that <math>\sum_i\operatorname{E}(X_i \mid \mathcal{H})</math> is additive for almost all H. However, this does not immediately follow because each <math>\operatorname{E}(X_i \mid \mathcal{H})</math> may have a different null set. Because countable unions of null sets are null sets, for a countable set of <math>X_i</math>, one can choose "versions" of each <math>\operatorname{E}(X_i \mid \mathcal{H})</math> with aligned null sets as to maintain additivity for almost all H. However, to align the "null sets of dysfunction" of <math>\operatorname{E}(X_i \mid \mathcal{H})</math> over all possible <math>X_i</math>, and thus treat <math>\operatorname{E}(X \mid \mathcal{H} = H)</math> as an almost surely unique measure over <math>\Omega</math> (a "regular probability measure"), we need further regularity conditions. Intuitively, to do this, we need to be able to approximate all possible <math>X_i</math> with a countable set of them. This directly corresponds to the conditions for creating a regular probability measure, which are separability and completeness. * The ''σ''-algebra <math>\mathcal{H}</math> controls the "granularity" of the conditioning. A conditional expectation <math>E(X\mid\mathcal{H})</math> over a finer (larger) ''σ''-algebra <math>\mathcal{H}</math> retains information about the probabilities of a larger class of events. A conditional expectation over a coarser (smaller) ''σ''-algebra averages over more events. ==== Conditional probability ==== {{Main|Regular conditional probability}} For a Borel subset {{mvar|B}} in <math>\mathcal{B}(\mathbb{R}^n)</math>, one can consider the collection of random variables :<math> \kappa_\mathcal{H}(\omega, B) := \operatorname{E}(1_{X \in B}|\mathcal{H})(\omega). </math> It can be shown that they form a [[Markov kernel]], that is, for almost all <math>\omega</math>, <math>\kappa_\mathcal{H}(\omega, -)</math> is a probability measure.<ref>{{cite book |last1=Klenke |first1=Achim |title=Probability theory : a comprehensive course |date=30 August 2013 |location=London |isbn=978-1-4471-5361-0 |edition=Second}}</ref> The [[Law of the unconscious statistician]] is then :<math> \operatorname{E}[f(X)\mid\mathcal{H}] = \int f(x) \kappa_\mathcal{H}(-, \mathrm{d}x), </math> This shows that conditional expectations are, like their unconditional counterparts, integrations, against a conditional measure. === General Definition === In full generality, consider: * A probability space <math>(\Omega,\mathcal{A},P)</math>. * A [[Banach space]] <math>(E,\|\cdot\|_E)</math>. * A [[Bochner integral|Bochner integrable]] random variable <math>X:\Omega\to E</math>. * A sub-''σ''-algebra <math>\mathcal{H}\subseteq \mathcal{A}</math>. The '''conditional expectation''' of <math>X</math> given <math>\mathcal{H}</math> is the up to a <math>P</math>-nullset unique and integrable <math>E</math>-valued <math>\mathcal{H}</math>-measurable random variable <math>\operatorname{E}(X \mid \mathcal{H})</math> satisfying :<math>\int_H \operatorname{E}(X \mid \mathcal{H}) \,\mathrm{d}P = \int_H X \,\mathrm{d}P</math> for all <math>H \in \mathcal{H}</math>.<ref>{{cite book|first1=Giuseppe|last1=Da Prato|first2=Jerzy|last2=Zabczyk|date=2014|title=Stochastic Equations in Infinite Dimensions|publisher=Cambridge University Press|doi=10.1017/CBO9781107295513|page=26|isbn=978-1-107-05584-1 }} (Definition in separable Banach spaces)</ref><ref>{{cite book|first1=Tuomas|last1=Hytönen|first2=Jan|last2=van Neerven|first3=Mark|last3=Veraar|first4=Lutz|last4=Weis|date=2016|title=Analysis in Banach Spaces, Volume I: Martingales and Littlewood-Paley Theory|publisher=Springer Cham|doi=10.1007/978-3-319-48520-1|isbn=978-3-319-48519-5 }} (Definition in general Banach spaces)</ref> In this setting the conditional expectation is sometimes also denoted in operator notation as <math>\operatorname{E}^\mathcal{H}X</math>. == Basic properties == All the following formulas are to be understood in an almost sure sense. The ''σ''-algebra <math>\mathcal{H}</math> could be replaced by a random variable <math>Z</math>, i.e. <math>\mathcal{H}=\sigma(Z)</math>. * Pulling out independent factors: ** If <math>X</math> is [[Independence (probability theory)|independent]] of <math>\mathcal{H}</math>, then <math>E(X\mid\mathcal{H}) = E(X)</math>. {{hidden begin|toggle=left|title=Proof}} Let <math>B \in \mathcal{H}</math>. Then <math>X</math> is independent of <math>1_B</math>, so we get that :<math>\int_B X\,dP = E(X1_B) = E(X)E(1_B) = E(X)P(B) = \int_B E(X)\,dP.</math> Thus the definition of conditional expectation is satisfied by the constant random variable <math>E(X)</math>, as desired. <math>\square</math> {{hidden end}} ** If <math>X</math> is independent of <math>\sigma(Y, \mathcal{H})</math>, then <math>E(XY\mid \mathcal{H}) = E(X) \, E(Y\mid\mathcal{H})</math>. Note that this is not necessarily the case if <math>X</math> is only independent of <math>\mathcal{H}</math> and of <math>Y</math>. ** If <math>X,Y</math> are independent, <math>\mathcal{G},\mathcal{H}</math> are independent, <math>X</math> is independent of <math>\mathcal{H}</math> and <math>Y</math> is independent of <math>\mathcal{G}</math>, then <math>E(E(XY\mid\mathcal{G})\mid\mathcal{H}) = E(X) E(Y) = E(E(XY\mid\mathcal{H})\mid\mathcal{G})</math>. * Stability: ** If <math>X</math> is <math>\mathcal{H}</math>-measurable, then <math>E(X\mid\mathcal{H}) = X</math>. {{hidden begin|toggle=left|title=Proof}} For each <math>H\in \mathcal{H}</math> we have <math>\int_H E(X\mid\mathcal{H}) \, dP = \int_H X \, dP</math>, or equivalently :<math> \int_H \big( E(X\mid\mathcal{H}) - X \big) \, dP = 0 </math> Since this is true for each <math>H \in \mathcal{H}</math>, and both <math>E(X\mid\mathcal{H})</math> and <math>X</math> are <math>\mathcal{H}</math>-measurable (the former property holds by definition; the latter property is key here), from this one can show :<math> \int_H \big| E(X\mid\mathcal{H}) - X \big| \, dP = 0 </math> And this implies <math> E(X\mid\mathcal{H}) = X</math> almost everywhere. <math>\square</math> {{hidden end}} ** In particular, for sub-''σ''-algebras <math>\mathcal{H}_1\subset\mathcal{H}_2 \subset\mathcal{F}</math> we have <math>E(E(X\mid\mathcal{H}_1)\mid\mathcal{H}_2) = E(X\mid\mathcal{H}_1)</math>. (Note this is different from the tower property below.) ** If ''Z'' is a random variable, then <math>\operatorname{E}(f(Z) \mid Z)=f(Z)</math>. In its simplest form, this says <math>\operatorname{E}(Z \mid Z)=Z</math>. * Pulling out known factors: ** If <math>X</math> is <math>\mathcal{H}</math>-measurable, then <math>E(XY\mid\mathcal{H}) = X \, E(Y\mid\mathcal{H})</math>. {{hidden begin|toggle=left|title=Proof}} All random variables here are assumed without loss of generality to be non-negative. The general case can be treated with <math>X = X^+ - X^-</math>. Fix <math>A \in \mathcal{H}</math> and let <math>X = 1_A</math>. Then for any <math>H \in \mathcal{H}</math> :<math>\int_H E(1_A Y \mid \mathcal{H}) \, dP = \int_H 1_A Y \, dP = \int_{A \cap H} Y \, dP = \int_{A\cap H} E(Y\mid\mathcal{H}) \, dP = \int_H 1_A E(Y \mid \mathcal{H}) \, dP </math> Hence <math> E(1_A Y \mid \mathcal{H}) = 1_A E(Y\mid\mathcal{H})</math> almost everywhere. Any simple function is a finite linear combination of indicator functions. By linearity the above property holds for simple functions: if <math>X_n</math> is a simple function then <math>E(X_n Y \mid \mathcal{H}) = X_n \, E(Y\mid \mathcal{H})</math>. Now let <math>X</math> be <math>\mathcal{H}</math>-measurable. Then there exists a sequence of simple functions <math>\{ X_n \}_{n\geq 1}</math> converging monotonically (here meaning <math>X_n \leq X_{n+1}</math>) and pointwise to <math>X</math>. Consequently, for <math>Y \geq 0 </math>, the sequence <math>\{ X_n Y \}_{n\geq 1}</math> converges monotonically and pointwise to <math> X Y </math>. Also, since <math>E(Y\mid\mathcal{H}) \geq 0</math>, the sequence <math>\{ X_n E(Y\mid\mathcal{H}) \}_{n\geq 1}</math> converges monotonically and pointwise to <math>X \, E(Y\mid\mathcal{H})</math> Combining the special case proved for simple functions, the definition of conditional expectation, and deploying the monotone convergence theorem: :<math> \int_H X \, E(Y\mid\mathcal{H}) \, dP = \int_H \lim_{n \to \infty} X_n \, E(Y\mid\mathcal{H}) \, dP = \lim_{n \to \infty} \int_H X_n E(Y\mid\mathcal{H}) \, dP = \lim_{n \to \infty} \int_H E(X_n Y\mid\mathcal{H}) \, dP = \lim_{n \to \infty} \int_H X_n Y \, dP = \int_H \lim_{n\to \infty} X_n Y \, dP = \int_H XY \, dP = \int_H E(XY\mid\mathcal{H}) \, dP</math> This holds for all <math>H\in \mathcal{H}</math>, whence <math>X \, E(Y\mid\mathcal{H}) = E(XY\mid\mathcal{H})</math> almost everywhere. <math>\square</math> {{hidden end}} ** If ''Z'' is a random variable, then <math>\operatorname{E}(f(Z) Y \mid Z)=f(Z)\operatorname{E}(Y \mid Z)</math>. * [[Law of total expectation]]: <math>E(E(X \mid \mathcal{H})) = E(X)</math>.<ref>{{Cite web|title=Conditional expectation|url=https://www.statlect.com/fundamentals-of-probability/conditional-expectation|access-date=2020-09-11|website=www.statlect.com}}</ref> * Tower property: ** For sub-''σ''-algebras <math>\mathcal{H}_1\subset\mathcal{H}_2 \subset\mathcal{F}</math> we have <math>E(E(X\mid\mathcal{H}_2)\mid\mathcal{H}_1) = E(X\mid\mathcal{H}_1)</math>. *** A special case <math>\mathcal{H}_1=\{\emptyset, \Omega\}</math> recovers the Law of total expectation: <math>E(E(X\mid\mathcal{H}_2) ) = E(X)</math>. *** A special case is when ''Z'' is a <math>\mathcal{H}</math>-measurable random variable. Then <math>\sigma(Z) \subset \mathcal{H}</math> and thus <math>E(E(X \mid \mathcal{H}) \mid Z) = E(X \mid Z)</math>. *** [[Doob martingale]] property: the above with <math>Z = E(X \mid \mathcal{H})</math> (which is <math>\mathcal{H}</math>-measurable), and using also <math>\operatorname{E}(Z \mid Z)=Z</math>, gives <math>E(X \mid E(X \mid \mathcal{H})) = E(X \mid \mathcal{H})</math>. ** For random variables <math>X,Y</math> we have <math>E(E(X\mid Y)\mid f(Y)) = E(X\mid f(Y))</math>. ** For random variables <math>X,Y,Z</math> we have <math>E(E(X\mid Y,Z)\mid Y) = E(X\mid Y)</math>. * Linearity: we have <math>E(X_1 + X_2 \mid \mathcal{H}) = E(X_1 \mid \mathcal{H}) + E(X_2 \mid \mathcal{H})</math> and <math>E(a X \mid \mathcal{H}) = a\,E(X \mid \mathcal{H})</math> for <math>a\in\R</math>. * Positivity: If <math>X \ge 0</math> then <math>E(X \mid \mathcal{H}) \ge 0</math>. * Monotonicity: If <math>X_1 \le X_2</math> then <math>E(X_1 \mid \mathcal{H}) \le E(X_2 \mid \mathcal{H})</math>. * [[Monotone convergence theorem|Monotone convergence]]: If <math>0\leq X_n \uparrow X</math> then <math>E(X_n \mid \mathcal{H}) \uparrow E(X \mid \mathcal{H})</math>. * [[Dominated convergence theorem|Dominated convergence]]: If <math>X_n \to X</math> and <math>|X_n| \le Y</math> with <math>Y \in L^1</math>, then <math>E(X_n \mid \mathcal{H}) \to E(X \mid \mathcal{H})</math>. * [[Fatou's lemma]]: If <math>\textstyle E(\inf_n X_n \mid \mathcal{H}) > -\infty</math> then <math>\textstyle E(\liminf_{n\to\infty} X_n \mid \mathcal{H}) \le \liminf_{n\to\infty} E(X_n \mid \mathcal{H})</math>. * [[Jensen's inequality]]: If <math>f \colon \mathbb{R} \rightarrow \mathbb{R}</math> is a [[convex function]], then <math>f(E(X\mid \mathcal{H})) \le E(f(X)\mid\mathcal{H})</math>. * [[Conditional variance]]: Using the conditional expectation we can define, by analogy with the definition of the [[variance]] as the mean square deviation from the average, the conditional variance ** Definition: <math>\operatorname{Var}(X \mid \mathcal{H}) = \operatorname{E}\bigl( (X - \operatorname{E}(X \mid \mathcal{H}))^2 \mid \mathcal{H} \bigr)</math> **Algebraic formula for the variance: <math>\operatorname{Var}(X \mid \mathcal{H}) = \operatorname{E}(X^2 \mid \mathcal{H}) - \bigl(\operatorname{E}(X \mid \mathcal{H})\bigr)^2</math> ** [[Law of total variance]]: <math>\operatorname{Var}(X) = \operatorname{E}(\operatorname{Var}(X \mid \mathcal{H})) + \operatorname{Var}(\operatorname{E}(X \mid \mathcal{H}))</math>. * [[Martingale convergence theorem|Martingale convergence]]: For a random variable <math>X</math>, that has finite expectation, we have <math>E(X\mid\mathcal{H}_n) \to E(X\mid\mathcal{H})</math>, if either <math>\mathcal{H}_1 \subset \mathcal{H}_2 \subset \dotsb</math> is an increasing series of sub-''σ''-algebras and <math>\textstyle \mathcal{H} = \sigma(\bigcup_{n=1}^\infty \mathcal{H}_n)</math> or if <math>\mathcal{H}_1 \supset \mathcal{H}_2 \supset \dotsb</math> is a decreasing series of sub-''σ''-algebras and <math>\textstyle \mathcal{H} = \bigcap_{n=1}^\infty \mathcal{H}_n</math>. * Conditional expectation as <math>L^2</math>-projection: If <math>X,Y</math> are in the [[Hilbert space]] of [[square-integrable]] real random variables (real random variables with finite second moment) then ** for <math>\mathcal{H}</math>-measurable <math>Y</math>, we have <math>E(Y(X - E(X\mid\mathcal{H}))) = 0</math>, i.e. the conditional expectation <math>E(X\mid\mathcal{H})</math> is in the sense of the [[Lp space|''L''<sup>2</sup>(''P'')]] scalar product the [[orthogonal projection]] from <math>X</math> to the [[linear subspace]] of <math>\mathcal{H}</math>-measurable functions. (This allows to define and prove the existence of the conditional expectation based on the [[Hilbert projection theorem]].) ** the mapping <math>X \mapsto \operatorname{E}(X\mid\mathcal{H})</math> is [[self-adjoint operator|self-adjoint]]: <math>\operatorname E(X \operatorname E(Y \mid \mathcal{H})) = \operatorname E\left(\operatorname E(X \mid \mathcal{H}) \operatorname E(Y \mid \mathcal{H})\right) = \operatorname E(\operatorname E(X \mid \mathcal{H}) Y)</math> * Conditioning is a [[Contraction (operator theory)|contractive]] projection of [[Lp space|''L''<sup>p</sup>]] spaces <math>L^p(\Omega, \mathcal{F}, P) \rightarrow L^p(\Omega, \mathcal{H}, P)</math>. I.e., <math>\operatorname{E}\big(|\operatorname{E}(X \mid\mathcal{H})|^p \big) \le \operatorname{E}\big(|X|^p\big)</math> for any ''p'' ≥ 1. * Doob's conditional independence property:<ref>{{Cite book|title=Foundations of Modern Probability|last=Kallenberg|first=Olav|publisher=Springer|year=2001|isbn=0-387-95313-2|edition=2nd|location=York, PA, USA|pages=110}}</ref> If <math>X,Y</math> are [[conditionally independent]] given <math>Z</math>, then <math>P(X \in B\mid Y,Z) = P(X \in B\mid Z)</math> (equivalently, <math>E(1_{\{X \in B\}}\mid Y,Z) = E(1_{\{X \in B\}} \mid Z)</math>). ==See also== {{Div col|colwidth=20em}} *[[Conditioning (probability)]] *[[Disintegration theorem]] *[[Doob–Dynkin lemma]] *[[Factorization lemma]] *[[Hidden Markov model]] *[[Joint probability distribution]] *[[Non-commutative conditional expectation]] {{Div col end}} === Probability laws === * [[Law of total cumulance]] (generalizes the other three) * [[Law of total expectation]] * [[Law of total probability]] * [[Law of total variance]] == Notes == {{reflist|refs= <ref name=kol1933>{{Cite book |title= Grundbegriffe der Wahrscheinlichkeitsrechnung |last= Kolmogorov |first= Andrey |author-link= Andrey Kolmogorov |year= 1933 |publisher= Julius Springer |location= Berlin |page= 46 |language= de |ref= kol1933 }} * Translation: {{cite book |title= Foundations of the Theory of Probability |edition= 2nd |last= Kolmogorov |first= Andrey |author-link= Andrey Kolmogorov |year= 1956 |publisher= Chelsea |location= New York |isbn= 0-8284-0023-7 |page= 53 |url= http://www.mathematik.com/Kolmogorov/index.html |ref= kol1956 |access-date= 2009-03-14 |archive-url= https://web.archive.org/web/20180914120850/http://www.mathematik.com/Kolmogorov/index.html |archive-date= 2018-09-14 |url-status= dead }}</ref> <ref name=halmos1950>{{cite journal |author=Oxtoby, J. C. |title= Review: ''Measure theory'', by P. R. Halmos |journal=Bull. Amer. Math. Soc. |year=1953 |volume=59 |issue=1 |pages=89–91 |url=https://www.ams.org/journals/bull/1953-59-01/S0002-9904-1953-09662-8/S0002-9904-1953-09662-8.pdf |doi=10.1090/s0002-9904-1953-09662-8 |ref=halmos1950 |doi-access=free }}</ref> <ref name=doob1953>{{cite book | author = J. L. Doob | title = Stochastic Processes | publisher = [[John Wiley & Sons]] | year = 1953 | isbn = 0-471-52369-0 | ref=doob1953 }}</ref> <ref name=billingsley1995>{{Cite book |last=Billingsley |first=Patrick |author-link=Patrick Billingsley |title=Probability and Measure |edition=3rd |publisher=John Wiley & Sons |year=1995 |isbn=0-471-00710-2 |section=Section 34. Conditional Expectation |page=445 |ref=bill1995 }}</ref> }} == References == {{Refbegin}} * [[William Feller]], ''An Introduction to Probability Theory and its Applications'', vol 1, 1950, page 223 * Paul A. Meyer, ''Probability and Potentials'', Blaisdell Publishing Co., 1966, page 28 * {{Cite book|last1=Grimmett|first1=Geoffrey|author-link=Geoffrey Grimmett |last2=Stirzaker|first2=David|title=Probability and Random Processes|year=2001|edition=3rd|publisher=Oxford University Press|isbn=0-19-857222-0}}, pages 67–69 {{Refend}} == External links == * {{Springer |title=Conditional mathematical expectation |id=c/c024500 |first=N.G. |last=Ushakov }} {{DEFAULTSORT:Conditional Expectation}} [[Category:Conditional probability]] [[Category:Statistical theory]]
Edit summary
(Briefly describe your changes)
By publishing changes, you agree to the
Terms of Use
, and you irrevocably agree to release your contribution under the
CC BY-SA 4.0 License
and the
GFDL
. You agree that a hyperlink or URL is sufficient attribution under the Creative Commons license.
Cancel
Editing help
(opens in new window)
Pages transcluded onto the current version of this page
(
help
)
:
Template:Cite book
(
edit
)
Template:Cite web
(
edit
)
Template:Div col
(
edit
)
Template:Div col end
(
edit
)
Template:Frac
(
edit
)
Template:Hidden begin
(
edit
)
Template:Hidden end
(
edit
)
Template:ISBN
(
edit
)
Template:Main
(
edit
)
Template:More footnotes needed
(
edit
)
Template:Mvar
(
edit
)
Template:Refbegin
(
edit
)
Template:Refend
(
edit
)
Template:Reflist
(
edit
)
Template:Short description
(
edit
)
Template:Springer
(
edit
)