Understand conditional probability and Bayes’ theorem
Conditional probability is defined as the likelihood of an event occurring, based on the occurrence of a given event.
[latex]P(A | B) = \dfrac{P(A \text{ and } B)}{P(B)}[/latex]
OR
[latex]P(A \text{ and } B) = P(A | B) \times P(B)[/latex]
Recall the example below: An urn has three red marbles and eight blue marbles in it. Draw two marbles, one at a time, this time without replacement, from the urn. Following is a tree diagram for this situation.
Find/calculate the following probabilities using the tree diagram:(a) [latex]P(R \text{ on the 2nd} | B \text{ on the 1st})[/latex]
(b) [latex]P(R \text{ on the 2nd} | R \text{ on the 1st})[/latex]
(c) [latex]P(\text{2nd one is }R)[/latex]
(d) [latex]P(B \text{ on the 1st} | R \text{ on the 2nd})[/latex]
(e) [latex]P(R \text{ on the 1st} | R \text{ on the 2nd})[/latex]
(a) [latex]P(R \text{ on the 2nd} | B \text{ on the 1st}) = \dfrac{3}{10}[/latex]
(b) [latex]P(R \text{ on the 2nd} | R \text{ on the 1st}) = \dfrac{2}{10}[/latex]
(c) [latex]P(\text{2nd one is }R) = P(BR) + P(RR) = \dfrac{24}{110} + \dfrac{6}{110} = \dfrac{30}{110}[/latex]
(d) [latex]P(B \text{ on the 1st} | R \text{ on the 2nd})[/latex]
Notice that for this question, the GIVEN information is on the second draw/stage. Remember that the condition gave us a new sample space.
This means that our new sample space are the events BR and RR only. The probability distribution table is as follows:
Events
Probability
BR
[latex]\dfrac{24}{110}[/latex]
RR
[latex]\dfrac{6}{110}[/latex]
Total
[latex]\dfrac{30}{110}[/latex]
So, [latex]P(B \text{ on the 1st} | R \text{ on the 2nd}) = \dfrac{P(BR)}{P(\text{2nd one is }R)} = \dfrac{\dfrac{24}{110}}{\dfrac{30}{110}}=\dfrac{24}{30}[/latex]
(e) [latex]P(R \text{ on the 1st} | R \text{ on the 2nd})[/latex]
This has similar ideas as part (d). Using the table on part (d), we have:
[latex]P(R \text{ on the 1st} | R \text{ on the 2nd}) = \dfrac{P(RR)}{P(\text{2nd one is }R)} = \dfrac{\dfrac{6}{110}}{\dfrac{30}{110}}=\dfrac{6}{30}[/latex]
Part (d) and (e) in the example above is also known as Bayes’ Theorem Probability.
Bayes’ Theorem
Bayes’ theorem or Bayes’ rule, named after Thomas Bayes[1], describes the probability of an event, based on the occurrence of another event.
Bayes’ Theorem
For events [latex]A[/latex] and [latex]B[/latex] and that [latex]P(B) \ne 0[/latex], the probability of event [latex]A[/latex] occurring given that event [latex]B[/latex] is true is:
[latex]P(A | B) = \dfrac{P(A \text{ and } B)}{P(B)} = \dfrac{P(B|A) \times P(A)}{P(B)}[/latex]
This tree diagram shows the tossing of an unfair coin followed by drawing one bead from a cup containing three red (R), four yellow (Y) and five blue (B) beads.
Find the probability that a flipped coin shows a head, given that the bead drawn is blue.
Mathematically, the question can be rewritten as: [latex]P(H | B)[/latex]Based on the formula above:
[latex]P(H | B) = \dfrac{P(H \text{ and } B)}{P(B)} = \dfrac{P(B|H) \times P(H)}{P(B)}=\dfrac{\dfrac{5}{12} \times \dfrac{2}{3}}{P(B)} = \dfrac{\dfrac{10}{36}}{P(B)}[/latex]
How do we find [latex]P(B)[/latex]?
Notice that there are two different possibilities to get [latex]B[/latex]. They are HB and TB.
So:
So, [latex]P(H | B) = \dfrac{\dfrac{10}{36}}{P(B)} = \dfrac{\dfrac{10}{36}}{\dfrac{15}{36}} = \dfrac{10}{15}[/latex]
A box contains 60 balls containing a variety of a colored balls, but all we know is 40% are red. In addition to colors, the balls are also made up of two sizes: small and large. Suppose we know that 50% of the red balls and 30% of the non-red balls are small. A person draws a ball at random from the box and notices it is a small ball. Let [latex]R =[/latex] be the event the ball is red and [latex]S =[/latex] the event the ball is small. What is the probability that it is red?