Conditional Probability
Introduction
Conditional Probability
Suppose are subsets of some sample space , written mathematically as . The probability of given is defined as
so long as .
We read the conditional probability statement as the probability of given, or conditioned on, . We think about this calculation as updating the probability of the probability of using the information contained in . If the set contains any information about , then .
Notice that conditional probability connects back to our definition of independent events; for , and are said to be independent if So if sets are independent, then the conditional probability of given is equal to the probability of Notice then that if are independent, then contains no information about and so .
Conditional Probability Examples
- In a school, there are 200 students. Among them, 120 are studying Mathematics, and 80 are studying Science. It is known that 60 students are studying both Mathematics and Science. You randomly pick a student who is studying Mathematics. What is the probability that the selected student is also studying Science?
- Consider the following table giving counts for the types of each
coffee purchased at my favorite coffee shop within a weekend.
Small Medium Large regular 19 23 22 decaf 20 15 17 - What is the probability that someone orders a decaf cup of coffee?
- Given that someone ordered a medium, what is the probability that their order is for a decaf cup of coffee?
- What is the probability that someone orders a small cup of coffee?
- Given that some ordered a regular cup of coffee, what is the probability that their order is for a small cup of coffee?
Bayes' Theorem
Baye's theorem is a combination of conditional probability and the Law of Total Probability.- Law of Total Probability
- For an arbitrary sample space and an arbitrary subset , let be a partition of . Then
The statement of the Law of Total Probability can be summarized by the following picture. In picture, it's a little easier to see that the area of , otherwise known as the probability of , , is composed of four subsets of . The four subsets are , , , and .
Because the sets for are mutually exclusive, we can use the third condition of distributions to find the probability of as the sum of the probability of these sets.
Theoretically, the collection of sets can be a partition of any super set of , . Most often though, the Law of Total Probability is framed as in the picture above, relative to the sample space .
- Bayes' Theorem
- Suppose and that . Bayes' Theorem states that
If necessary, the Law of Total Probability can be used to calculate the denominator. Bayes' Theorem is the formula that allows you to compute the probability of given using the probability given ; effecitively, the set being conditioned on is swapped for the set on which probability is being calculated, .
Bayes' Theorem Examples
- A factory produces three types of widgets: Type A, Type B, and Type C. The production ratios are such that 50% of the widgets produced are Type A, 30% are Type B, and 20% are Type C. Each widget is then independently tested, and it is found that 5% of Type A widgets, 3% of Type B widgets, and 10% of Type C widgets fail the test. A widget is randomly selected from the production line and is found to have failed the test. What is the probability that this widget is a Type C widget?
- In a certain population, 1% of people have a specific genetic disorder. There is a diagnostic test for this disorder, which has a 95% sensitivity (meaning that it correctly identifies 95% of those who have the disorder) and a 98% specificity (meaning that it correctly identifies 98% of those who do not have the disorder). A medical student picks a random individual from this population and administers the test, which comes back positive. Calculate the probability that this individual actually has the genetic disorder, given that their test result is positive.
- A civil engineering company is working on a large infrastructure project. Historical data shows that there's a 70% chance of encountering significant geological challenges when building in this region. If such challenges are encountered, the probability of project delays is 80%. However, if no geological challenges are encountered, the probability of delays due to other factors is only 10%. Given that a project is delayed, what is the probability that it was due to geological challenges?
References
Conditional probability. Wikipedia: The Free Encyclopedia. Wikimedia Foundation, Inc. Accessed 2024-04-11.
Law of total probability. Wikipedia: The Free Encyclopedia. Wikimedia Foundation, Inc. Accessed 2024-04-11.
Partition of a set. Wikipedia: The Free Encyclopedia. Wikimedia Foundation, Inc. Accessed 2024-04-11.