2.4 Conditional Probability
2.4: Conditional Probability
Learning Objectives
Upon completion of this section, you should be able to
- Compute conditional probabilities
- Compute probability using the multiplication rule
- Compute probability with independent events
Conditional Probability
Imagine you’re playing a game with a fair six-sided die. Someone rolls the die behind a screen and asks you, “What’s the probability that it’s a five?” Initially, you’d say , right? There are six possible outcomes, and they’re all equally likely.
Now imagine if they then tell you, “The number is odd”? This new information changes things. Now you know the roll must be 1, 3, or 5. Out of these three possibilities, only one is a five. So your new answer would be .
This scenario introduces us to conditional probability. Conditional probability asks: “What is the likelihood of an event, given that we know something else has already happened?” In probability notation, we write this as , which means “the probability of event A, given that event B has occurred.”
In our die example:
Event A: Rolling a five
Event B: Rolling an odd number
: The probability of rolling a five, given that we know the roll was odd
This concept of updating probabilities based on new information is crucial in many real-world applications, from weather forecasting to medical diagnoses.
Conditional Probability
Conditional probability is the likelihood of an event occurring, given that another event has already occurred. It measures how the probability of one event changes when we have information about another related event.
The conditional probability of event occurring, given that event has occurred, is denoted as and is read as “the probability of given .”
General Formula:
Where
Example 1
A fair die is rolled.
- Find the probability that the number rolled is a five, given that it is odd.
- Find the probability that the number rolled is odd, given that it is a five.
Solution
The sample space for this experiment is the set consisting of six equally likely outcomes. Let denote the event “a five is rolled” and let denote the event “an odd number is rolled,” so that .
- This is the introductory example, so we already know that the answer is . To use the formula in the definition to confirm this we must replace in the formula (the event whose likelihood we seek to estimate) by and replace (the event we know for certain has occurred) by :
We know
We also know that
Thus,
- This is the same problem, but with the roles of and reversed. Since we are given that the number that was rolled is five, which is odd, the probability in question must be 1. To apply the formula to this case we must now replace (the event whose likelihood we seek to estimate) by and (the event we know for certain has occurred) by :
Now .
From part (a) we found that . Thus,
Just as we did not need the computational formula in this example, we do not need it when the information is presented in a two-way contingency table, as in the next example.
Example 2
In a sample of 902 individuals under 40 who were or had previously been married, each person was classified according to gender and age at first marriage. The results are summarized in the following two-way classification table, where the meaning of the labels is:
- : male
- : female
- : a teenager when first married
- : in one’s twenties when first married
- : in one’s thirties when first married
E | W | H | Total | |
---|---|---|---|---|
M | 43 | 293 | 114 | 450 |
F | 82 | 299 | 71 | 452 |
Total | 125 | 592 | 185 | 902 |
The numbers in the first row mean that 43 people in the sample were men who were first married in their teens, 293 were men who were first married in their twenties, 114 men who were first married in their thirties, and a total of 450 people in the sample were men. Similarly for the numbers in the second row. The numbers in the last row mean that, irrespective of gender, 125 people in the sample were married in their teens, 592 in their twenties, 185 in their thirties, and that there were 902 people in the sample in all. Suppose that the proportions in the sample accurately reflect those in the population of all individuals in the population who are under 40 and who are or have previously been married. Suppose such a person is selected at random.
- Find the probability that the individual selected was a teenager at first marriage.
- Find the probability that the individual selected was a teenager at first marriage, given that the person is male.
Solution
It is natural to let also denote the event that the person selected was a teenager at first marriage and to let denote the event that the person selected is male.
- According to the table the proportion of individuals in the sample who were in their teens at their first marriage is . This is the relative frequency of such people in the population, hence or about 14%.
- Since it is known that the person selected is male, all the females may be removed from consideration, so that only the row in the table corresponding to men in the sample applies:
E W H Total M 43 293 114 450 The proportion of males in the sample who were in their teens at their first marriage is . This is the relative frequency of such people in the population of males, hence or about 10%.
Example 3
- Find the probability that the person selected suffers hypertension given that they are overweight.
- Find the probability that the selected person suffers hypertension given that they are not overweight.
- Compare the two probabilities just found to give an answer to the question as to whether overweight people tend to suffer from hypertension.
Solution
Let denote the event “the person selected suffers hypertension.” Let denote the event “the person selected is overweight.” The probability information given in the problem may be organized into the following contingency table:
O | Oc | |
---|---|---|
H | 0.09 | 0.11 |
Hc | 0.02 | 0.78 |
- Using the formula in the definition of conditional probability,
- Using the formula in the definition of conditional probability,
- is over six times as large as , which indicates a much higher rate of hypertension among people who are overweight than among people who are not overweight. It might be interesting to note that a direct comparison of and does not answer the same question.
Try it Now 1
The table below shows the number of survey subjects who have received and not received a speeding ticket in the last year, and the color of their car. Find the probability that a randomly chosen person:
- Has a speeding ticket given they have a red car
- Has a red car given they have a speeding ticket
Speeding ticket | No speeding ticket | Total | |
---|---|---|---|
Red car | 15 | 135 | 150 |
Not red car | 45 | 470 | 515 |
Total | 60 | 605 | 665 |
Hint 1 (click to Show/Hide)
Both of these questions be answered by zooming in on the given information and taking the appropriate ratio. For (a) we would want to look at just the row for having a red car. For (b) we would want to look at just the column of having a speeding ticket.
Answer (click to Show/Hide)
- Since we know the person has a red car, we are only considering the 150 people in the first row of the table. Of those, 15 have a speeding ticket, so
- Since we know the person has a speeding ticket, we are only considering the 60 people in the first column of the table. Of those, 15 have a red car, so
Notice from the Try It Now 1 that is not equal to .
These kinds of conditional probabilities are what insurance companies use to determine your insurance rates. They look at the conditional probability of you having accident, given your age, your car, your car color, your driving history, etc., and price your policy based on that likelihood.
Multiplication Rule
If we rewrite the conditional probability formula we have another tool to answer questions about probability
involving “and“.
General Multiplication Rule
Given that and are both events that have probabilities that are not zero we can say the following about the probability of and together.
In the definition above please note this does not mean we are saying and are equal to each other (or the conditional probabilities listed)
This manipulation of the conditional probability formula gives us another way of finding the probability of and (this also means the intersection of with ). It is not always needed when computing the probability of an intersection (the Addition Rule also can be manipulated or if we know the events and are independent we can use the rule from the previous section).
Example 4
If you pull 2 cards out of a deck one after the other and keep both, then what is the probability that both
are spades?
Solution
Let be the event that the first card drawn is a space and be the event that the second card drawn is a space. We are looking to find the probabilty that both and occur: .
The probability that the first card is a spade is .
If the first card drawn is a spade we can find the probability of the second card is a spade by counting the total number of spades left and dividing it by the total number of cards left. The probability that the second card is a spade, given the first was a spade, is , since there is one less spade in the deck, and one less total cards.
The probability that both cards are spades is:
Video Solution of the Example (4 mins 28 secs – CC)
Example 5
If you draw two cards from a deck (one after the other), what is the probability that you will get the Ace of Diamonds and a black card?
Solution
You can satisfy this condition by having Case A or Case B, as follows:
- Case A: you can get the Ace of Diamonds first and then a black card
- Case B: you can get a black card first and then the Ace of Diamonds
Let be the event we draw the Ace of Diamonds on the first card, be the event we draw the Ace of Diamonds on the second draw, be the event we draw a black card on the first card, and be the event we draw a black card on the second draw.
Let’s calculate the probability of Case A. The probability that the first card is the Ace of Diamonds is . The probability that the second card is black given that the first card is the Ace of Diamonds is because 26 of the remaining 51 cards are black.
The probability for Case A is:
Now for Case B: the probability that the first card is black is . The probability that the second card is the Ace of Diamonds given that the first card is black is .
The probability of Case B is therefore
Recall that the probability of or is . In this problem, since the first card cannot be the Ace of Diamonds and be a black card. Therefore, the probability of Case A or Case B is . The probability that you will get the Ace of Diamonds and a black card when drawing two cards from a deck is .
Video Solution of the Example (1 min 55 secs – CC) Another example starts after the 1:55 mark of the video.
Try it Now 2
In your drawer you have 10 pairs of socks, 6 of which are white. If you reach in and randomly grab two pairs of socks, what is the probability that both are white?
Hint 1 (click to Show/Hide)
In order for both to be white we have to have the first drawn to be white and then given that the first is white the second sock drawn is white as well. The key here is that given piece as it tells us we are dealing with conditional probability.
Answer (click to Show/Hide)
Let be the event we draw a white sock on the first draw and the event we draw a white sock on the second draw. We are looking to find
Now the multiplication rule can help us as it can be rewritten as:
, since we have 6 white socks out of the ten when we draw the first sock from the drawer.
, since we are assuming A has occured (we already drawn a sock from the drawer and it was white). The first sock being white means we now have five white socks out of the nine remaining socks in the drawer.
Put the two above together into the formula to get: .
Let us put our knowledge of conditional probability, complements, and the multiplication rule to a test in this next Try It Now.
Try it Now 3
The probability that event occurs is .63. The probability that event occurs is .45. The probability that both events occur is .10.
Find the following probabilities by using the definition of conditional probability and Venn Diagrams:
Hint 1 (click to Show/Hide)
Start with writing out the given information in probability notation. You will also need the following three formulas:
Hint 2 (click to Show/Hide)
If you are stuck try writing out the definition of conditional probabilty for each one to see if it leads to a solution with the given information you already have.
Answer (click to Show/Hide)
The answers along with formulas/steps are given below. To see an alternative approach using Venn Diagrams see the video link much further below.
- : The complement rule was used, but note how the given information doesn’t change. Only the event of
interest in the conditional probability has the complement taken. - This one takes many different steps to find expressions we are able to use. Started with the general conditional probability formula, but then used the complement rule in the denominator and the multiplication rule in the numerator to eventually get a form we can evaluate from our work in c above.
- This one also starts with applying the formula for consitional probability and the use of the multiplication rule and complement rule:
Now parts d and e are a challenge to construct on your own from just the formulas. There is approach for each of these using a more visual construction for the formulas to get the final result. Watch the Try It Now Video (10 mins 55 secs – CC) for an explanation of how it works.
Independent Events
With conditional probability we saw how some events can often influence each other. However, sometimes events occur without affecting the likelihood of other events. We call these independent events.
Consider an example related to insurance company assessing risks on a home insurance policy:
: A house experiences storm damage this year
: The same house had a burglary last year
These events are likely independent because a past burglary doesn’t influence the chances of future storm damage.
Although typically we expect the conditional probability to be different from the probability , it does not have to be true. When , the occurrence of has no effect on the likelihood of . Whether or not the event has occurred is independent of the event .
Independent
Events and are independent if .
If and are not independent we say they are dependent.
Using algebra it can be shown that the equality holds if and only if the equality holds, which in turn is true if and only if .
The formula in the definition has two practical but exactly opposite uses:
- In a situation in which we can compute all three probabilities , , and , it is used to check whether or not the events and are independent:
- If , then and are independent.
- If , then and are not independent.
- In a situation in which each of and can be computed and it is known that and are independent, then we can compute by multiplying together and : .
Example 6
A single fair die is rolled. Let and . Are and independent?
Solution
In this example we can compute all three probabilities , , and .
The product is not the same number as , the events and are not independent.
Example 7
Many diagnostic tests for detecting diseases do not test for the disease directly but for a chemical or biological product of the disease, hence are not perfectly reliable. The sensitivity of a test is the probability that the test will be positive when administered to a person who has the disease. The higher the sensitivity, the greater the detection rate and the lower the false negative rate.
Suppose the sensitivity of a diagnostic procedure to test whether a person has a particular disease is 92%. A person who actually has the disease is tested for it using this procedure by two independent laboratories.
- What is the probability that both test results will be positive?
- What is the probability that at least one of the two test results will be positive?
Solution
- Let denote the event “the test by the first laboratory is positive” and let denote the event “the test by the second laboratory is positive.” Since and are independent,
- Using the Additive Rule for Probability and the probability just computed,
Example 8
The specificity of a diagnostic test for a disease is the probability that the test will be negative when administered to a person who does not have the disease. The higher the specificity, the lower the false positive rate.
Suppose the specificity of a diagnostic procedure to test whether a person has a particular disease is 89%.
- A person who does not have the disease is tested for it using this procedure. What is the probability that the test result will be positive?
- A person who does not have the disease is tested for it by two independent laboratories using this procedure. What is the probability that both test results will be positive?
Solution
- Let denote the event “the test result is positive.” The complement of is that the test result is negative, and has probability the specificity of the test, 0.89. Thus
- Let denote the event “the test by the first laboratory is positive” and let denote the event “the test by the second laboratory is positive.” Since and are independent, by part (a) of the example
Example 9
A jar contains 10 marbles, 7 black and 3 white. Two marbles are drawn without replacement, which means that the first one is not put back before the second one is drawn.
- What is the probability that both marbles are black?
- What is the probability that exactly one marble is black?
- What is the probability that at least one marble is black?
Solution
A tree diagram for the situation of drawing one marble after the other without replacement is shown in “Tree Diagram for Drawing Two Marbles”. The circle and rectangle will be explained later, and should be ignored for now.
The number to the right of each final node is computed as shown, using the principle that if the formula in the Conditional Rule for Probability is multiplied by , then the result is
- The event “both marbles are black” is and corresponds to the top right node in the tree, which has been circled. Thus as indicated there, it is:
- The event “exactly one marble is black” corresponds to the two nodes of the tree enclosed by the rectangle. The events that correspond to these two nodes are mutually exclusive: black followed by white is incompatible with white followed by black . Thus in accordance with the Additive Rule for Probability we merely add the two probabilities next to these nodes. Thus the probability of drawing exactly one black marble in two tries is:
- The event “at least one marble is black” corresponds to the three nodes of the tree enclosed by either the circle or the rectangle. The events that correspond to these nodes are mutually exclusive, so as in part (b) we merely add the probabilities next to these nodes. Thus the probability of drawing at least one black marble in two tries is 0.47+0.23+0.23=0.93.
Of course, this answer could have been found more easily using the Probability Law for Complements, simply subtracting the probability of the complementary event, “two white marbles are drawn,” from 1 to obtain 1−0.07=0.93.
Try it Now 4
Are these events independent?
- A fair coin is tossed two times. The two events are (1) first toss is a head and (2) second toss is a head.
- The two events (1) “It will rain tomorrow in Tucson” and (2) “It will rain tomorrow in Phoenix” (a city near Tucson).
- You draw a red card from a deck, then draw a second card without replacing the first.
- A coin is tossed and you record Heads or Tails, and you roll a die and record the outcome.
Answer (click to Show/Hide)
- The probability that a head comes up on the second toss is 1/2 regardless of whether or not a head came up on the first toss, so these events are independent.
- These events are not independent because it is more likely that it will rain in Phoenix on days it rains in Tucson than on days it does not.
- The probability of the second card depends on what the first card drawn is, so these events are not independent.
- These are independent as the outcome of the coin toss would not change based on the outcome of the dice roll.
Try it Now 5
A card is pulled from a deck of cards and noted. The card is then replaced, the deck is shuffled, and a second card is removed and noted. What is the probability that both cards are Aces?
Hint 1 (click to Show/Hide)
Can we state the events of drawing those two cards are independent? If we can then we can use the multiplication rule for independent events. If we can’t establish independence, then we have to try something different.
Answer (click to Show/Hide)
Since the second draw is made after replacing the first card, these events are independent. The probability of an ace on each draw is , so the probability of an Ace on both draws is .
WARNING!!!! Independent ≠ Disjoint (mutually exclusive)
The concepts of independent and mutually exclusive events are often confused.
- These are events that cannot happen at the same time.
- If one occurs, the other cannot occur.
Independent Events:
- The occurrence of one event doesn’t affect the probability of the other event.
- Knowing one event happened doesn’t change the likelihood of the other event.
For example let us take a standard 52-card deck. We will define two events
Event : Drawing a black card
Event : Drawing a heart
These events are mutually exclusive, since a card can’t be both black and a heart (red) at the same time.
, but if we know the card is black, .
This shows that knowing the card is black changes the probability of it being a heart. Therefore, these events are not independent.
Remember:
- For independent events:
- For mutually exclusive events:
Exercises
- For two events A and B, P(A)=0.73, P(B)=0.48, and P(A∩B)=0.29.
- Find P(A|B).
- Find P(B|A).
- Determine whether or not A and B are independent.
Answer (click to Show/Hide)
- They are not independent as
- For two events A and B, P(A)=0.26, P(B)=0.37, and P(A∩B)=0.11.
- Find P(A|B).
- Find P(B|A).
- Determine whether or not A and B are independent.
Answer (click to Show/Hide)
- They are not independent as
- For two events A and B, P(A)=0.25, P(B)=0.6, and P(A∩B)=0.15.
- Find P(A|B).
- Find P(B|A).
- Determine whether or not A and B are independent.
- Determine whether or not A and B are mutually exclusive.
Answer (click to Show/Hide)
- They are independent as has been verified.
- They are not mutually exclusive as the probability of and is not zero.
- Compute the following probabilities in connection with the roll of a single fair die.
- The probability that the roll is even.
- The probability that the roll is even, given that it is not a two.
- The probability that the roll is even, given that it is not a one.
- Compute the following probabilities in connection with two tosses of a fair coin.
- The probability that the second toss is heads.
- The probability that the second toss is heads, given that the first toss is heads.
- The probability that the second toss is heads, given that at least one of the two tosses is heads.
- A special deck of 16 cards has 4 that are blue, 4 yellow, 4 green, and 4 red. The four cards of each color are numbered from one to four. A single card is drawn at random. Find the following probabilities.
- The probability that the card drawn is red.
- The probability that the card is red, given that it is not green.
- The probability that the card is red, given that it is neither red nor yellow.
- The probability that the card is red, given that it is not a four.
- A special deck of 16 cards has 4 that are blue, 4 yellow, 4 green, and 4 red. The four cards of each color are numbered from one to four. A single card is drawn at random. Find the following probabilities.
- The probability that the card drawn is a two or a four.
- The probability that the card is a two or a four, given that it is not a one.
- The probability that the card is a two or a four, given that it is either a two or a three.
- The probability that the card is a two or a four, given that it is red or green.
- A random experiment gave rise to the two-way contingency table shown. Use it to compute the probabilities indicated.
R S A 0.12 0.18 B 0.28 0.42 - P(A), P(R), P(A∩R).
- Based on the answer to (a), determine whether or not the events A and R are independent.
- Based on the answer to (b), determine whether or not P(A|R) can be predicted without any computation. If so, make the prediction. In any case, compute P(A|R) using the Rule for Conditional Probability.
- A random experiment gave rise to the two-way contingency table shown. Use it to compute the probabilities indicated.
R S A 0.13 0.07 B 0.61 0.19 - P(A), P(R), P(A∩R).
- Based on the answer to (a), determine whether or not the events A and R are independent.
- Based on the answer to (b), determine whether or not P(A|R) can be predicted without any computation. If so, make the prediction. In any case, compute P(A|R) using the Rule for Conditional Probability.
- Suppose for events A and B in a random experiment P(A)=0.70 and P(B)=0.30. Compute the indicated probability, or explain why there is not enough information to do so.
- P(A∩B).
- P(A∩B), with the extra information that A and B are independent.
- P(A∩B), with the extra information that A and B are mutually exclusive.
- Suppose for events A and B connected to some random experiment, P(A)=0.50 and P(B)=0.50. Compute the indicated probability, or explain why there is not enough information to do so.
- P(A∩B).
- P(A∩B), with the extra information that A and B are independent.
- P(A∩B), with the extra information that A and B are mutually exclusive.
- The following two-way contingency table gives the breakdown of the population of patrons at a grocery store according to the number of items purchased and whether or not the patron made an impulse purchase at the checkout counter:
Number of Items Impulse Purchase Made Not Made Few 0.01 0.19 Many 0.04 0.76 A patron is selected at random. Find each of the following probabilities.
- The patron made an impulse purchase.
- The patron made an impulse purchase, given that the total number of items purchased was many.
- Determine whether or not the events “few purchases” and “made an impulse purchase at the checkout counter” are independent.
- The sensitivity of a drug test is the probability that the test will be positive when administered to a person who has actually taken the drug. Suppose that there are two independent tests to detect the presence of a certain type of banned drugs in athletes. One has sensitivity 0.75; the other has sensitivity 0.85. If both are applied to an athlete who has taken this type of drug, what is the chance that his usage will go undetected?
- A person has two lights in their well house to keep the pipes from freezing in winter. They check the lights daily. Each light has probability 0.002 of burning out before it is checked the next day (independently of the other light).
- If the lights are wired in parallel one will continue to shine even if the other burns out. In this situation, compute the probability that at least one light will continue to shine for the full 24 hours. Note the greatly increased reliability of the system of two bulbs over that of a single bulb.
- If the lights are wired in series neither one will continue to shine even if only one of them burns out. In this situation, compute the probability that at least one light will continue to shine for the full 24 hours. Note the slightly decreased reliability of the system of two bulbs over that of a single bulb.
- Events A and B are mutually exclusive. Find P(A|B).
- A basketball player makes 60% of the free throws that he attempts, except that if he has just tried and missed a free throw then his chances of making a second one go down to only 30%. Suppose he has just been awarded two free throws.
- Find the probability that he makes both.
- Find the probability that he makes at least one. (A tree diagram could help.)
- Suppose a jar contains 17 red marbles and 32 blue marbles. If you reach in the jar and pull out 2 marbles at random one at a time without replacement, find the probability that both are red.
- Suppose you write each letter of the alphabet on a different slip of paper and put the slips into a hat. If you pull out two slips at random (one at a time without replacement), find the probability that both are vowels (a, e, i, o , or u).
- A math class consists of 25 students, 14 female and 11 male. Two students are selected at random to participate in a probability experiment. Compute the probability that
- a male is selected, then a female.
- a female is selected, then a male.
- two males are selected.
- two females are selected.
- no males are selected.
- A math class consists of 25 students, 14 female and 11 male. Three students are selected at random to participate in a probability experiment. Compute the probability that
- a male is selected, then two females.
- a female is selected, then two males.
- two females are selected, then one male.
- three males are selected.
- three females are selected.
- A jar contains 6 red marbles numbered 1 to 6 and 8 blue marbles numbered 1 to 8. A marble is drawn at random from the jar. Find the probability the marble is red or odd-numbered.
- A jar contains 4 red marbles numbered 1 to 4 and 10 blue marbles numbered 1 to 10. A marble is drawn at random from the jar. Find the probability the marble is blue or even-numbered.
- A jar contains 5 red marbles numbered 1 to 5 and 8 blue marbles numbered 1 to 8. A marble is drawn at random from the jar. Find the probability the marble is
- Even-numbered given that the marble is red.
- Red given that the marble is even-numbered.
- A jar contains 4 red marbles numbered 1 to 4 and 8 blue marbles numbered 1 to 8. A marble is drawn at random from the jar. Find the probability the marble is
- Odd-numbered given that the marble is blue.
- Blue given that the marble is odd-numbered.
- Compute the probability of flipping a coin and getting heads, given that the previous flip was tails.
- Find the probability of rolling a “1” on a fair die, given that the last 3 rolls were all ones.
- Suppose a math class contains 25 students, 14 females (three of whom speak French) and 11 males (two of whom speak French). Compute the probability that a randomly selected student speaks French, given that the student is female.
- Suppose a math class contains 25 students, 14 females (three of whom speak French) and 11 males (two of whom speak French). Compute the probability that a randomly selected student is male, given that the student speaks French.
- Forty eight percent of all undergraduates at a large university are male, 18% are majoring in business, and 10% are male and are majoring in business. Let be the event that a randomly selected undergraduate is male and let be the event that a randomly selected undergraduate is majoring in business.
- Compute and . Interpret these results (include what the value is and what it represents in terms of the application).
- Are and independent? (justify your answer using the definition of independence from this section)
Attributions
- This page contains modified content from David Lippman, “Math In Society, 2nd Edition.” Licensed under CC BY-SA 4.0.
- This page contains modified content from “College Algebra 2017.” Lumen Learning. Licensed under CC BY 4.0.
- This page contains modified content from Introductory Statistics Copyright © 2024 by LOUIS: The Louisiana Library Network is licensed under a Creative Commons Attribution-ShareAlike 4.0 International License, except where otherwise noted.
- This page contains content by Robert Foth, Math Faculty, Pima Community College, 2021. Licensed under CC BY 4.0.