Introduction to Data Mining

<<< Previous    Up    Next >>>

Lesson 4

Conditional Independence

 

    Two events A and B are said to be independent events if the occurrence of B does not depend on the occurrence of event A and visa versa. I.e. The probability of an event A is unchanged before and after event B has occurred.

                P(A/B) = P(A)

Two events are independent only and only if

                P(A/B) = P(A) and P(B/A) = P(B)

Otherwise they are said to be dependent.

 

Example:- Two cards are drawn from a deck, with replacement. Event A is that the first card is an ace, while event B is that the second card is a spade. Find the probability, P(B/A).

Answer:- P(A) = 4/52 = 1/13. and initially P(B) = 13/52 = 1/4

Since the first card is replaced, the deck will now have 52 cards , with 13 spades. So

P(B/A) = 13/52 = 1/4.

Hence P(B/A) = P(B) and so A and B are independent events.

 

Consider the product rule,

P(A ∩ B) = P(B/A).P(A)

                  = P(B).P(A)                          by definition of condition independence

This is known as the multiplicative rule for conditional independence.

Example:- Two cards are drawn from a deck, with replacement. Event A is that the first card is an ace, while event B is that the second card is a spade. Find the probability P(A ∩ B).

Answer:- We know that P(B/A) = P(B) = 1/4.

Similarly, P(A/B) = P(A) = 1/13.

Hence P(A ∩ B) = P(B).P(A) = 1/4 * 1/13 = 1/52.

 

The multiplicative rule can be extended to more than two independent events, i.e. if A1, A2,......,Ak are k independent events then,

P(A1 ∩ A2 ∩ .......... ∩ Ak) = P(A1).P(A2).P(A3).........P(Ak)

For a more general case (when events A1, A2,......,Ak are not necessarily independent)

P(A1 ∩ A2 ∩ .......... ∩ Ak) = P(A1).P(A2/A1).P(A3/A1 ∩ A2).............. P(Ak/A1 ∩ A2 ∩ A3 ∩..... ∩ Ak).

Example:- Three cards are drawn from a deck, without replacement. Find the probability P(A1 ∩ A2 ∩ A3) such that A1 = the first card is a red ace, and A2 = the second card is a 10 or a Jack, and A3 = the third card is greater than 3 but smaller than 7.

Answer:- There are two red aces in 52 cards, so P(A1) = 2/52.

There are now 51 cards left, with four 10s and four Jacks, so P(A2) = 8/51.

There are now 50 cards left, with four 4s, four 5s and four 6s, so P(A3) = 12/50.

P(A1 ∩ A2 ∩ A3) = 2/52 * 8/51 * 12/50

                          = 8/5525.

 

Exercises:

  1. Find the probability of randomly selecting 4 good cans of milk from a cooler, which has 20 cans of milk with 5 spoiled cans.

  2. The probability of Kevin being alive in 20 years is 0.7 and the probability that Anne is alive after 20 years is 0.9. If we assume that both events are independent. Find the probability hat both are not alive after 20 years.

  3. The probability that a person visiting a dentist will have an X-ray is 0.6; the probability that a person who has had an X-ray will also have a cavity is 0.3; the probability that a person who has had an X-ray and has a cavity filled will also have his tooth extracted is 0.1. Find the probability that a person visiting a dentist will have an X-ray and a cavity filled and also have his tooth extracted.

 

<<< Previous    Up    Next >>>