Tutorials › Stochastic Processes › Conditional Probabilities as Martingales

Martingales: Definitions and Examples · Tutorial 710 of 994

Conditional Probabilities as Martingales

Learn why the probability of a finite-horizon event, updated as observations arrive, is a martingale—and how to calculate each conditional probability.

Advanced 10 min read

What You'll Learn

  • Define the conditional-probability process for an event measurable at a finite horizon.
  • Prove its martingale property using the tower property of conditional expectation.
  • Explain why the process is bounded and equals the event indicator at the terminal time.
  • Calculate conditional probabilities for a run-of-heads event at every observation stage.
  • Distinguish conditional probabilities on positive-probability histories from arbitrary values on null histories.
  • Identify the error in keeping an event's unconditional probability fixed after observations arrive.

Updating the Probability of an Event

Suppose an event depends on a finite sequence of observations, but those observations are revealed one at a time. Before any observations, the event has some probability. After the first observation, its conditional probability may change; after the next observation, it may change again. Although the values change with the information available, they satisfy a precise consistency rule: the next conditional probability has the current conditional probability as its conditional mean. That rule makes the process a martingale.

Work on a probability space \((\Omega,\mathcal{F},\mathbb{P})\). Let \((\mathcal{F}_n)_{n\ge 0}\) be a filtration, meaning that each \(\mathcal{F}_n\) is a sigma-field and \(\mathcal{F}_n\subseteq\mathcal{F}_{n+1}\). It represents the information available by time \(n\). Let \(A\in\mathcal{F}_N\) be an event determined by information available by a fixed finite time \(N\). Define

$$ M_n=\mathbb{E}[\mathbf{1}_A\mid\mathcal{F}_n],\qquad 0\le n\le N. $$

Here \(\mathbf{1}_A\) is \(1\) on \(A\) and \(0\) otherwise. The conditional expectation is defined up to equality almost surely, so \(M_n\) is also defined up to equality almost surely. It is a version of the conditional probability of \(A\) given the information at time \(n\). If the observations have finitely many possible histories, then on any history \(H\in\mathcal{F}_n\) with \(\mathbb{P}(H)>0\), its value is \(\mathbb{P}(A\mid H)=\mathbb{P}(A\cap H)/\mathbb{P}(H)\). A history of probability zero has no such ratio; the value of a version there can be chosen arbitrarily.

Theorem: If \(A\in\mathcal{F}_N\), then \(M_n=\mathbb{E}[\mathbf{1}_A\mid\mathcal{F}_n]\), for \(0\le n\le N\), is a martingale with respect to \((\mathcal{F}_n)\). Moreover, \(0\le M_n\le 1\) almost surely, \(\mathbb{E}[M_n]=\mathbb{P}(A)\), and \(M_N=\mathbf{1}_A\) almost surely.

Proof. For each \(n\), \(M_n\) is \(\mathcal{F}_n\)-measurable by the definition of conditional expectation. Since \(0\le\mathbf{1}_A\le1\), monotonicity of conditional expectation gives \(0\le M_n\le1\) almost surely; in particular, \(M_n\) is integrable. For \(n<N\), the tower property and \(\mathcal{F}_n\subseteq\mathcal{F}_{n+1}\) give \(\mathbb{E}[M_{n+1}\mid\mathcal{F}_n]=\mathbb{E}[\mathbb{E}[\mathbf{1}_A\mid\mathcal{F}_{n+1}]\mid\mathcal{F}_n]=\mathbb{E}[\mathbf{1}_A\mid\mathcal{F}_n]=M_n\) almost surely. These are the martingale conditions. Taking expectations in the definition gives \(\mathbb{E}[M_n]=\mathbb{E}[\mathbf{1}_A]=\mathbb{P}(A)\). Finally, \(A\in\mathcal{F}_N\) means \(\mathbf{1}_A\) is \(\mathcal{F}_N\)-measurable, so its conditional expectation given \(\mathcal{F}_N\) equals \(\mathbf{1}_A\) almost surely. \(\square\)

The theorem does not say that the conditional probability stays fixed along each observed history. It says that before the next observation, the average of the updated values, conditional on the information already available, is the current value. The terminal statement is also important: once all information determining \(A\) has been observed, the conditional probability is \(1\) if \(A\) occurred and \(0\) otherwise. If the filtration continues beyond \(N\), then for every \(n\ge N\), \(\mathbb{E}[\mathbf{1}_A\mid\mathcal{F}_n]=\mathbf{1}_A\) almost surely, since \(A\in\mathcal{F}_N\subseteq\mathcal{F}_n\).

A Coin-Toss Event Tracked Through Time

Worked Example: At Least One Pair of Consecutive Heads

Flip a fair coin three times. The probability space consists of the eight equally likely sequences in \(\{H,T\}^3\), each with probability \(1/8\). Let \(X_1,X_2,X_3\) denote the tosses, let \(\mathcal{F}_0=\{\varnothing,\Omega\}\), and let \(\mathcal{F}_n=\sigma(X_1,\ldots,X_n)\) for \(1\le n\le3\). Let \(A\) be the event that the sequence contains \(HH\) in positions 1–2 or 2–3. We compute \(M_n=\mathbb{P}(A\mid\mathcal{F}_n)\) on every positive-probability history.

At time \(0\), the successful sequences are \(HHH,HHT,THH\): the first two contain \(HH\) in positions 1–2, and \(THH\) contains it in positions 2–3. Thus \(\mathbb{P}(A)=3/8\), so \(M_0=3/8\).

After the first toss is \(H\), the second toss completes the event if it is \(H\). If the second toss is \(T\), the third toss cannot create a consecutive pair, because the first toss was \(H\) and the second was \(T\). The conditional probability is therefore \(\mathbb{P}(A\mid X_1=H)=1/2\). After the first toss is \(T\), the event requires the last two tosses to be \(HH\), giving \(\mathbb{P}(A\mid X_1=T)=1/4\).

After two tosses, the history \(HH\) has already made \(A\) certain, so the conditional probability is \(1\). For history \(HT\), the event is impossible, so it is \(0\). For history \(TH\), the third toss must be \(H\), giving probability \(1/2\). For history \(TT\), the third toss cannot complete a pair, giving probability \(0\). At time \(3\), the value is the indicator of \(A\). The full calculation is:

TimeObserved historyConditional probability
0No tosses\(3/8\)
1\(H\)\(1/2\)
1\(T\)\(1/4\)
2\(HH\)\(1\)
2\(HT\)\(0\)
2\(TH\)\(1/2\)
2\(TT\)\(0\)
3\(HHH,HHT,THH\)\(1\)
3\(HTH,HTT,THT,TTH,TTT\)\(0\)

Check the martingale averages. At time \(0\), the two first-toss histories each have probability \(1/2\), and their conditional probabilities average to \(\tfrac12(\tfrac12)+\tfrac12(\tfrac14)=\tfrac14+\tfrac18=\tfrac38=M_0\). Given history \(H\), the next-toss values are \(1\) after \(HH\) and \(0\) after \(HT\), so their average is \(\tfrac12(1)+\tfrac12(0)=\tfrac12=M_1\) on that history. Given history \(T\), the next values are \(1/2\) after \(TH\) and \(0\) after \(TT\), giving \(\tfrac12(\tfrac12)+\tfrac12(0)=\tfrac14=M_1\). At time \(2\), each history has two equally likely children. For \(HH\), both terminal values are \(1\), with average \(1\); for \(HT\), both are \(0\), with average \(0\); for \(TH\), the values are \(1,0\), with average \(1/2\); and for \(TT\), both are \(0\), with average \(0\). Each average equals the conditional probability listed for its history. The terminal values also match \(\mathbf{1}_A\) on all eight sequences.

Conditional Probabilities Need Not Be Fairly Split

The next example shows the same martingale calculation when the observation histories are not all equally likely. Conditioning must use the probability of the observed history; the martingale property still follows by averaging with the correct conditional probabilities.

Worked Example: Comparing Two Die Rolls

Roll a fair six-sided die twice, with independent outcomes \(Y_1,Y_2\in\{1,2,3,4,5,6\}\). The probability space has 36 equally likely ordered pairs. Let \(A=\{Y_1<Y_2\}\), \(\mathcal{F}_0=\{\varnothing,\Omega\}\), \(\mathcal{F}_1=\sigma(Y_1)\), and \(\mathcal{F}_2=\sigma(Y_1,Y_2)\).

There are \(5+4+3+2+1+0=15\) ordered pairs with first outcome smaller than second, so \(M_0=\mathbb{P}(A)=15/36=5/12\). If \(Y_1=k\), then \(6-k\) of the six possible second outcomes are strictly greater than \(k\). Thus \(M_1=(6-Y_1)/6\). In order \(k=1,2,3,4,5,6\), these values are \(5/6,4/6,3/6,2/6,1/6,0\).

Given \(Y_1=k\), each second outcome has conditional probability \(1/6\), and at time \(2\) the conditional probability is \(\mathbf{1}_{\{k<Y_2\}}\). Its conditional mean is \((6-k)/6=M_1\). For example, with \(Y_1=4\), the successful second outcomes are \(5,6\), so the average terminal indicator is \((0+0+0+0+1+1)/6=2/6=1/3=M_1\). Averaging over the first die also checks the initial value: \(\tfrac16(\tfrac56+\tfrac46+\tfrac36+\tfrac26+\tfrac16+0)=\tfrac{15}{36}=\tfrac5{12}=M_0\). At time \(2\), \(M_2=\mathbf{1}_{\{Y_1<Y_2\}}\), as required.

Why the Martingale Property Matters

The conditional-probability process provides a disciplined way to track how evidence changes the probability of a future or partially observed event. A value that rises after one observation may fall after another; what cannot happen is a systematic change in its conditional average. In applications, this makes such processes useful for analyzing sequential evidence and for constructing martingales from events. The event must be measurable at the stated finite horizon for the terminal identity \(M_N=\mathbf{1}_A\) to apply. The martingale identity itself follows from conditional expectation and the nested information sets, not from independence of the observations.

Common mistake: retaining the unconditional probability after seeing data. For two fair tosses, let \(A\) be the event that both tosses are heads. The unconditional probability is \(1/4\). A wrong calculation sets the conditional probability to \(1/4\) both before and after the first toss. But if the first toss is \(H\), the event now requires only that the second toss be \(H\), so \(\mathbb{P}(A\mid X_1=H)=1/2\). If the first toss is \(T\), the event is impossible, so \(\mathbb{P}(A\mid X_1=T)=0\). The correction respects the martingale average: \(\tfrac12(\tfrac12)+\tfrac12(0)=\tfrac14\). The unconditional probability is the average before the first toss, not the conditional probability on every history.

Another point of care is the meaning of conditional probabilities on null histories. The ratio formula applies only when the conditioning event has positive probability. For histories of probability zero, a conditional-expectation version can be assigned values without changing any almost-sure martingale statement. In finite examples with fair coins or dice, every listed history has positive probability, so the ratio formula is valid throughout.

Check Your Understanding

For each question, specify the information available at the relevant time and verify any claimed martingale step by conditional averaging.

  1. For three fair tosses, what is the conditional probability of at least one pair of consecutive heads after observing \(TH\)?
  2. In the coin example, compute the average of the time-2 conditional probabilities over all four two-toss histories and compare it with \(M_0\).
  3. For two independent fair die rolls, what is \(\mathbb{P}(Y_1<Y_2\mid Y_1=2)\), and what is the average terminal indicator given \(Y_1=2\)?
  4. Why does \(M_N=\mathbf{1}_A\) almost surely when \(A\in\mathcal{F}_N\)?
  5. For a history \(H\) with \(\mathbb{P}(H)=0\), why can one not calculate \(\mathbb{P}(A\mid H)\) using the ratio \(\mathbb{P}(A\cap H)/\mathbb{P}(H)\)?