Independent Events & Conditional Probability

advertisement
Independent Events & Conditional Probability
Conditional Probability
For two events A and B, the probability of A given B, which is written as P A | B  , is
defined as follows:
P A | B  
P A  B 
P B 
This tells us that of the fraction of times B has occurred, what fraction of the time has A
occurred. To find this, we no longer need to look for the fraction of times A occurs in our
sample space, but only the portion of A that is in B, i.e. A  B , and compare this to the
fraction of times that B occurs.
Consider the following example:
The probability that a rare tropical disease will be diagnosed correctly is 0.25, the
probability that when a person is diagnosed correctly the disease will be cured is 0.80,
and the probability that a person will be cured even though the diagnosis was incorrect is
0.12. What is the probability that a person will be cured of the disease?


Let D be the event that the diagnosis is correct
Let C be the event that a person is cured of the disease
In terms of these events, we are given the following information about probabilities:



PD  0.25
PC | D  0.80
o This is saying that of all the correct diagnoses that are made, 0.80 of these
will be cured
PC | D C   0.12
o This is saying that of all the incorrect diagnoses that are made, 0.12 of
these will be cured
Questions to consider:
1.
2.
3.
4.
What percentage of people will be diagnosed correctly and cured?
What percentage of people will be diagnosed incorrectly and cured?
What percentage of people will be cured?
What percentage of people will not be cured?
Let’s make a Venn Diagram for this problem. I’m going to divide up our sample space
by correct diagnoses and incorrect diagnoses.
So if you’re in the green region your diagnosis is correct and if you’re in the blue region
your diagnosis was incorrect. Because these two events are mutually exclusive (i.e. a
person cannot both be diagnosed correctly and incorrectly), these two sets have no
overlap. Further, the people who are cured overlap into both the green and the blue as
shown below:
So, if you’re inside the ellipse part of our Venn diagram you’ve been cured. Now, let’s
look at several regions of this Venn diagram.
Region #
1
2
3
4
Verbal Description
A person was correctly diagnosed AND cured of the disease
A person was correctly diagnosed BUT not cured
A person was incorrectly diagnosed AND cured of the disease
A person was incorrectly diagnosed AND not cured
Now how does this relate to the probabilities that we wrote earlier?

First, the probability that you’re in the green part of the sample space is
PD  0.25 .

Second, the probability that you’re in the blue part of the sample space is
PD C   0.75 .

Third, of all the people who are in the green part, 0.80 are in region 1. In other
words: PD  C   PDPC | D  0.25  0.80  0.20 .



Fourth, PD  C C   PD   PD  C   0.25  0.20  0.05 .
Fifth, of all the people who are in the blue part, 0.12 are in region 3. In other
words: PC  D C   PD C PC | D C   0.75  0.12  0.09 .
Sixth, PD C  C C   PD C   PC  D C   0.75  0.09  0.66 .
Returning to the four questions that were posed earlier:
1. What percentage of people will be diagnosed correctly and cured?
PD  C   PDPC | D  0.25  0.80  0.20
2. What percentage of people will be diagnosed incorrectly and cured?
PC  D C   PD C PC | D C   0.75  0.12  0.09
3. What percentage of people will be cured?
PC   PD  C   PC  D C   PD PC | D   PD C PC | D C   0.20  0.09  0.29
4. What percentage of people will not be cured?
PC C   1  PC   1  0.29  0.71
We could have also used a tree diagram to solve this problem. Here’s what the tree
diagram would look like:
Notice that you could be cured in two ways:
1. with a correct diagnosis
2. with an incorrect diagnosis
To find the probability you simply multiply across each branch of the tree. Each time
you multiply across each branch you are computing the probability of the intersection.
For example, suppose we multiplied across the branch for a correct diagnosis and cured:
PC PC | D  0.25  0.80  PC  D
We should be surprised by this result because from the definition of conditional
probability:
P C | D  
PC  D 
P D 
Multiplying both sides of the equation by PD  shows:
PC | DPD  PC  D
Independent Events
With conditional probability, we can see that the occurrence of one event can affect the
probability of another event occurring. One question we might be interested in is
whether or not this true for any two events?
For example, let’s look at two events:


S: the event you take a shower today
K: the event you scrape your knee on the sidewalk
Does the fact that you took a shower today influence whether you will scrape your knee
on the sidewalk? Experience would tell us that the two events are unrelated to each
other. When the occurrence of one event does NOT affect the occurrence of another
event, we say the two events are independent of each other.
In terms of the two events that we defined above, mathematically we can convey the idea
of independent events by saying:
PK | S   PK 
This last equation says that the probability of your scraping your knee is unaffected by
the occurrence of taking a shower today. From our previous discussion of conditional
probability we can also rewrite the above equation as:
P K  S 
 P K 
P S 
P K  S   P K P S 
This last equation gives us another way of looking at independent events. It basically
says that if two events K and S are independent then the product of their individual
probabilities is equal to the probability of their intersection.
Let’s look at independent events with an example.
Suppose that you flip a coin twice. Lets say that H 1 represents the event you get a head
on the first flip, H 2 is the event you get a head on the second flip, and so on. What is the
probability that you would get a head on the second flip given that you had a head on the
first flip?
In terms of the events we’ve defined, we are asking for PH 2 | H1  . Now looking at this
problem from personal experience, we could argue that each flip is unaffected by what
took place on the previous flip. In other words:
PH 2 | H1   PH 2 
Now we can actually verify this mathematically by using the fact that two events are
independent if the product of their individual probabilities is equal to the probability of
their intersection. In other words:
PH1  H 2   PH1 PH 2 
Looking at the sample space for this problem we have:
S  HH , HT , TH , TT 
The P H 1  H 2   P HH  
P H 1 P H 2  
1
. Comparing this quantity with
4
1 1 1
  , we see that in fact H 1 and H 2 are independent.
2 2 4
Let’s extend our example a little further and flip three coins now. What’s the probability
of getting a head on the third flip give that the previous two flips were heads?
Mathematically, we want PH 3 | H 1  H 2  . Again, we should expect to see that getting
a head on the third flip is unaffected by having two heads on the previous two flips. In
other words:
PH 3 | H 1  H 2   PH 3 
To show this is in fact the case we need to show that
PH 1  H 2  H 3   PH 3 PH 1  H 2 
From the previous calculation, we already showed that PH1  H 2   PH1 PH 2  . So
for this calculation, we need to show:
PH 1  H 2  H 3   PH 3 PH 1  H 2   PH1 PH 2 PH 3 
The sample space for flipping a coin three times is:
S  HHH , HHT , HTH , HTT , THH , THT , THH , TTT 
From this P H 1  H 2  H 3  
1
.
8
Likewise P H 1 P H 2 P H 3  
1 1 1 1
   .
2 2 2 8
So this shows that getting a head on the third flip is unaffected by having heads on the
previous two flips. In other words, H 1 , H 2 , and H 3 are all independent of each other.
In fact, independence is nice not only for events in the sample space, but events that are
conditioned on some other event. Mathematically, this means that two events E and F
are independent given that some other event, say H has occurred if:
PE  F | H   PE | H PF | H 
And likewise:
PE  F  G | H   PE | H PF | H PG | H 
Mutually Exclusive Vs. Independent Events
It is important that you’re able to distinguish between events that are mutually exclusive
and events that are independent. The two ARE NOT the same. If we return to the
example first introduced for taking a shower and scraping your knee, we can see the two
events were independent but NOT mutually exclusive since it is possible for you to
scrape your knee and take a shower. For two events A and B, the following table will
help to distinguish between mutually exclusive and independent events:
Mutually
Exclusive
Independent
Probabilities
P A  B  0
Verbal Description
Both events cannot happen
The occurrence of B does not affect the
P  A | B   P  A
P  A  B   P  AP B  occurrence of A
Download