Post · 4 min read· pp. 92–94
As we mentioned earlier, almost any concept that is defined for probability can also be extended
to conditional probability. Remember that two events A and B are independent if
P(A∩B)=P(A)P(B),or equivalently, P(A∣B)=P(A).
We can extend this concept to conditionally independent events. In particular,
Definition
Two events A and B are conditionally independent given an event C with P(C)>0 if
P(A∩B∣C)=P(A∣C)P(B∣C)(1.8)
Recall that from the definition of conditional probability,
P(A∣B)=P(B)P(A∩B),
if
P(B)>0. By conditioning on
C, we obtain
P(A∣B,C)=P(B∣C)P(A∩B∣C)
if
P(B∣C),P(C)=0. If
A and
B are conditionally independent given
C, we obtain
| |
|---|
| P(A∣B,C) | =P(B∣C)P(A∩B∣C) |
| =P(B∣C)P(A∣C)P(B∣C) |
| =P(A∣C). |
Thus, if A and B are conditionally independent given C, then
P(A∣B,C)=P(A∣C)(1.9)
Thus, Equations
1.8 and
1.9 are equivalent statements of the definition of
conditional independence. Now let's look at an example.
Example
A box contains two coins: a regular coin and one fake two-headed coin (P(H)=1). I choose
a coin at random and toss it twice. Define the following events.
- A= First coin toss results in an H.
- B= Second coin toss results in an H.
- C= Coin 1 (regular) has been selected.
Find P(A∣C),P(B∣C),P(A∩B∣C),P(A),P(B), and P(A∩B). Note that A
and B are NOT independent, but they are conditionally independent given C.
- Solution
We have P(A∣C)=P(B∣C)=21. Also, given that Coin 1 is selected, we have
P(A∩B∣C)=21.21=41. To find P(A),P(B), and
P(A∩B), we use the law of total probability:
| |
|---|
| P(A) | $ =P(A |
| =21⋅21+1⋅21 |
| =43. |
Similarly, P(B)=43. For P(A∩B), we have
| |
|---|
| P(A∩B) | $ = P(A \cap B |
| =P(A∣C)P(B∣C)P(C)+P(A∣Cc)P(B∣Cc)P(Cc) |
| $\hspace{120pt} \textrm{ (by conditional independence of A and B)}$ |
| =21⋅21⋅21+1⋅1⋅21 |
| =85. |
As we see, P(A∩B)=85=P(A)P(B)=169, which means that A and B
are not independent. We can also justify this intuitively. For example, if we know A has
occurred (i.e., the first coin toss has resulted in heads), we would guess that it is more
likely that we have chosen Coin 2 than Coin 1. This in turn increases the conditional probability
that B occurs. This suggests that A and B are not independent. On the other hand, given C
(Coin 1 is selected), A and B are independent.
One important lesson here is that, generally speaking, conditional independence neither implies (nor
is it implied by) independence. Thus, we can have two events that are conditionally independent but
they are not unconditionally independent (such as A and B above). Also, we can have two events
that are independent but not conditionally independent, given an event C. Here is a simple
example regarding this case. Consider rolling a die and let
A={1,2},
B={2,4,6},
C={1,4}.
Then, we have
P(A)=31,P(B)=21;
P(A∩B)=61=P(A)P(B).
Thus,
A and
B are independent. But we have
P(A∣C)=21,P(B∣C)=21;
P(A∩B∣C)=P({2}∣C)=0.
Thus
P(A∩B∣C)=P(A∣C)P(B∣C),
which means
A and
B are not conditionally independent given
C.