Tutorials › Probability Theory (Graduate) › Computing Conditional Expectations on Finite Partitions

Conditional Expectation · Tutorial 232 of 946

Computing Conditional Expectations on Finite Partitions

Compute conditional expectations on finite partitions by averaging over each positive-probability atom, while handling null atoms without changing the almost-sure result.

Intermediate 9 min read

What You'll Learn

  • Express a finite sigma-algebra as the collection of unions of partition atoms.
  • Compute the conditional expectation on each positive-probability atom using an integral average.
  • Verify the formula using the defining integral condition for conditional expectation.
  • Explain why values assigned on null atoms do not affect the conditional expectation.
  • Calculate conditional expectations from discrete joint probability tables.

Why finite partitions make conditioning concrete

Conditional expectation is defined through measurability and integral identities. When the conditioning sigma-algebra is generated by a finite partition, those requirements reduce to a direct calculation: on each partition atom, take the average of the random variable over that atom.

This gives a useful way to compute conditional expectations without searching for an unknown random variable. It also makes an important qualification visible. An atom of probability zero has no meaningful average, and the value assigned there is unrestricted by the defining integral condition.

Finite partitions and their sigma-algebras

Definition: A finite measurable partition of \(\Omega\) is a finite collection \(\Pi=\{A_1,\ldots,A_m\}\) of nonempty, pairwise disjoint measurable sets whose union is \(\Omega\). The sigma-algebra generated by the partition, denoted \(\sigma(\Pi)\), consists of all unions of its atoms, including \(\varnothing\). The sets \(A_i\) are called the atoms of this finite sigma-algebra.

Thus, an event in \(\sigma(\Pi)\) cannot select only part of an atom: it either contains the whole atom or none of it. For example, if \(\Pi=\{A_1,A_2,A_3\}\), then \(\sigma(\Pi)\) contains \(A_1\cup A_3\), but it does not contain a proper subset of \(A_1\) unless that subset can also be expressed as a union of atoms.

Let \(X\) be an integrable real-valued random variable. Recall the defining condition for a conditional expectation given \(\sigma(\Pi)\): a random variable \(Z\) is a version of \(\mathbb{E}[X\mid\sigma(\Pi)]\) if it is integrable, measurable with respect to \(\sigma(\Pi)\), and satisfies \(\int_B Z\,d\mathbb{P}=\int_B X\,d\mathbb{P}\) for every \(B\in\sigma(\Pi)\).

Formula on the atoms: For each atom \(A_i\) with \(\mathbb{P}(A_i)>0\), set \[ c_i=\frac{1}{\mathbb{P}(A_i)}\int_{A_i}X\,d\mathbb{P}. \] Then a version of \(\mathbb{E}[X\mid\sigma(\Pi)]\) is the random variable that equals \(c_i\) on each positive-probability atom \(A_i\). On any atom with probability zero, its value may be chosen arbitrarily; choosing zero is a convenient convention.

The numerator is the total integral of \(X\) over the atom, and the denominator is the probability mass of that atom. Their ratio is the average value of \(X\) conditional on lying in that atom. The formula applies to general integrable \(X\), not only to random variables with finitely many values.

Why the formula works

Theorem: Let \(X\) be integrable and let \(\Pi=\{A_1,\ldots,A_m\}\) be a finite measurable partition. Define \(Z\) by the atomwise formula above, assigning any finite value on each null atom. Then \(Z\) is a version of \(\mathbb{E}[X\mid\sigma(\Pi)]\).
Proof. The function \(Z\) is constant on each atom, so it is measurable with respect to \(\sigma(\Pi)\). There are finitely many atoms and \(Z\) takes a finite value on each one, so \(Z\) is integrable. Now let \(B\in\sigma(\Pi)\). By the definition of the generated sigma-algebra, \(B\) is a union of some of the atoms. For a positive-probability atom \(A_i\), \[ \int_{A_i}Z\,d\mathbb{P} =c_i\mathbb{P}(A_i) =\int_{A_i}X\,d\mathbb{P}. \] For a null atom \(A_i\), both integrals are zero: the integral of an integrable random variable over a null set is zero, and the integral of the finite constant assigned to \(Z\) over \(A_i\) is also zero. Adding these equalities over the finitely many atoms making up \(B\) gives \[ \int_B Z\,d\mathbb{P}=\int_B X\,d\mathbb{P}. \] Thus \(Z\) satisfies the defining condition for the conditional expectation. \(\square\)

This proof uses only the finite partition structure: every conditioning event is a union of whole atoms, so checking the integral identity atom by atom is enough.

What is determined on each atom?

The averaging formula determines the value on every atom of positive probability. On null atoms it determines nothing. This is consistent with the almost-sure uniqueness of conditional expectation: changing a random variable on a null set does not change its almost-sure equivalence class.

Proposition: If \(Z\) is a version of \(\mathbb{E}[X\mid\sigma(\Pi)]\), then on every positive-probability atom \(A_i\), it is almost surely equal to \(\mathbb{P}(A_i)^{-1}\int_{A_i}X\,d\mathbb{P}\). Values on null atoms are immaterial to the defining integral conditions.
Proof. A real-valued \(\sigma(\Pi)\)-measurable function is constant on each atom, apart from any choice of representative on a null set. Indeed, if it took two different values within an atom, a rational number between those values would make a sublevel set split that atom. Such a sublevel set could not be a union of atoms, contradicting \(\sigma(\Pi)\)-measurability. Write \(z_i\) for the constant value of \(Z\) on a positive-probability atom \(A_i\). The defining integral identity applied to \(B=A_i\) gives \[ z_i\mathbb{P}(A_i)=\int_{A_i}X\,d\mathbb{P}. \] Since \(\mathbb{P}(A_i)>0\), division yields \[ z_i=\frac{1}{\mathbb{P}(A_i)}\int_{A_i}X\,d\mathbb{P}. \] On a null atom, both sides of the defining integral identity over that atom are zero regardless of the finite value assigned to \(Z\). Hence the identity cannot impose a value there. \(\square\)

Worked Example: Averaging over parity of a die roll

Worked Example: Averaging over parity of a die roll

Let \(\Omega=\{1,2,3,4,5,6\}\), with each outcome having probability \(1/6\), and let \(X(k)=k\). Condition on the partition into odd and even outcomes: \[ A_{\mathrm{odd}}=\{1,3,5\},\qquad A_{\mathrm{even}}=\{2,4,6\}. \] Each atom has probability \(3/6=1/2\). On the odd atom, \[ \mathbb{E}[X\mid A_{\mathrm{odd}}] =\frac{(1+3+5)/6}{3/6} =\frac{9}{3} =3. \] On the even atom, \[ \mathbb{E}[X\mid A_{\mathrm{even}}] =\frac{(2+4+6)/6}{3/6} =\frac{12}{3} =4. \] Thus a version of the conditional expectation equals \(3\) on odd outcomes and \(4\) on even outcomes. To check the defining condition, the integral over the odd atom is \(3(1/2)=3/2\), which equals \((1+3+5)/6\); over the even atom it is \(4(1/2)=2\), which equals \((2+4+6)/6\). The condition then holds for every union of these two atoms.

Worked Example: A conditional average from a joint distribution

Worked Example: A conditional average from a joint distribution

Suppose \(X\) takes values \(0,1,2\), and \(Y\) takes values \(a,b,c,d\). The joint probability masses are as follows; the row for \(d\) has total probability zero.

\(Y\)\(\mathbb{P}(X=0,Y)\)\(\mathbb{P}(X=1,Y)\)\(\mathbb{P}(X=2,Y)\)\(\mathbb{P}(Y)\)
\(a\)\(0.1\)\(0.2\)\(0.1\)\(0.4\)
\(b\)\(0\)\(0.1\)\(0.3\)\(0.4\)
\(c\)\(0.2\)\(0\)\(0\)\(0.2\)
\(d\)\(0\)\(0\)\(0\)\(0\)

The atoms of \(\sigma(Y)\) are the events \(\{Y=a\},\{Y=b\},\{Y=c\},\{Y=d\}\). For \(Y=a\), the integral of \(X\) over the atom is \[ 0(0.1)+1(0.2)+2(0.1)=0.4, \] so the average is \(0.4/0.4=1\). For \(Y=b\), it is \[ 0(0)+1(0.1)+2(0.3)=0.7, \] and the average is \(0.7/0.4=1.75\). For \(Y=c\), the integral is \(0(0.2)+1(0)+2(0)=0\), giving average \(0/0.2=0\). The atom \(\{Y=d\}\) is null, so its average is undefined; assign the conditional expectation the value \(0\) there. The resulting version takes the values \(1,1.75,0,0\) on the four atoms, respectively.

Worked Example: A null atom in a continuous probability space

Worked Example: A null atom in a continuous probability space

Let \(\Omega=[0,1]\) with Lebesgue probability measure, let \(X(t)=t\), and use the partition \(\Pi=\{\{0\},(0,1]\}\). The singleton \(\{0\}\) has probability zero, while \((0,1]\) has probability one. The average on the positive-probability atom is \[ \frac{1}{\mathbb{P}((0,1])}\int_{(0,1]}t\,dt =\int_0^1t\,dt =\frac12. \] Thus one version equals \(1/2\) throughout \((0,1]\). Its value at \(0\) may be chosen to be \(0\), \(17\), or any other finite number. For either choice, the integral over \(\{0\}\) is zero, and the integral over \((0,1]\) is \(1/2\), matching the integral of \(X\) over each atom. The two choices differ only on a null set and therefore represent the same conditional expectation almost surely.

A common pitfall

Do not divide by the probability of every atom without first checking that it is positive. If an atom has probability zero, the expression \(\int_A X\,d\mathbb{P}/\mathbb{P}(A)\) is not defined. The right procedure is to calculate the average only on positive-probability atoms and then assign any finite value on null atoms.

For a finite-valued conditioning variable \(Y\), the atoms are the events \(\{Y=y\}\) for its possible values \(y\). The same rule applies: average \(X\) over each event with positive probability, and treat probability-zero values separately. This atomwise description is often the simplest way to interpret a conditional expectation: it records the average of \(X\) at the level of detail retained by the conditioning partition.

Check Your Understanding

Use the atomwise formula and the defining integral condition to answer the following.

  1. If an atom \(A\) has positive probability, what value must a version of \(\mathbb{E}[X\mid\sigma(\Pi)]\) take on \(A\), up to almost-sure equality?
  2. Why is it enough to verify the integral identity on each atom of a finite partition?
  3. What is the conditional expectation formula on an atom where \(X\) takes finitely many values?
  4. Why does the formula not assign a uniquely determined value on a null atom?
  5. In the die example, what would the conditional expectation be on the atom \(\{1,2\}\) if the partition were \(\{\{1,2\},\{3,4,5,6\}\}\)?
Clinical Biostats