Professional Documents
Culture Documents
Introduction To Probability - 1 PDF
Introduction To Probability - 1 PDF
INTRODUCTION TO PROBABILITY
Outline
• Probability
• Adding Probabilities
Probability
• We have all seen examples of probability
– What is the probability that a coin lands on heads when
flipped?
– What is the probability that I draw a King from a shuffled
deck of cards?
– What is the probability that the stock market goes up by
more than 5% over the next 12 months?
– What is 𝑃 𝐴 ∪ 𝐵 ?
Events
• What is 𝑃 𝐴 ∩ 𝐵 in general?
JOINT PROBABILITY
Outline
• Conditional Probability
• Joint probability
• Marginal Probability
Independent Events
• Two events are said to be independent if knowing that one of the events
occurred does not impact the probability of the other event occurring
• Mutually exclusive: 𝑃 𝐴 ∩ 𝐵 = 0
• Independent: 𝑃 𝐴 ∩ 𝐵 = P A × 𝑃(𝐵)
• P(diamond | red) = ½
• P(red | diamond) = 1
Conditional Probability
• 𝑃 𝐴 ∩ 𝐵 = P A B P(B)
• 𝑃 𝐴 ∩ 𝐵 = P B A P(A)
Conditional Probability
• P(red ∩ diamond)
– P(diamond | red) P(red) = ½ * ½ = ¼
– P(red | diamond) P(diamond) = 1 * ¼ = ¼
• In the contingency table we have that summing over rows gives the
probability of being in a column
• We call this the marginal probability
BAYES’ RULE
Outline
• Bayes’ Rule
• Examples
Bayes’ Rule
• Remember we developed a new product rule for dependent events?
– 𝑃 𝐴 ∩ 𝐵 = P A B P(B)
– 𝑃 𝐴 ∩ 𝐵 = P B A P(A)
• These two equations have the same left hand side
• That means the right hand sides must be equal
– P B A P A = P A B P(B)
𝑃 𝑑𝑒𝑓𝑎𝑢𝑙𝑡 𝑃(ℎ𝑖𝑔ℎ|𝑑𝑒𝑓𝑎𝑢𝑙𝑡)
• 𝑃 𝑑𝑒𝑓𝑎𝑢𝑙𝑡 ℎ𝑖𝑔ℎ =
𝑃(ℎ𝑖𝑔ℎ)
5% × 10%
• = = 2%
25%
Bayes’ Rule
• Remember I told you the law of total probability would
be useful
𝑃(𝐴|𝐵)𝑃(𝐵)
• 𝑃 𝐵𝐴 =
𝑃(𝐴|𝐵)𝑃(𝐵) +𝑃(𝐴|𝑛𝑜𝑡 𝐵)𝑃(𝑛𝑜𝑡 𝐵)
Bayes’ Rule
• Suppose a disease affects 1% of the population. There is a test for
this disease, but it’s not perfect; 5% of people with the disease will
test negative and 7% of people without the disease will test positive
• If you test positive what is the probability you have the disease?
• It seems like the answer is 93% - it’s not!
95% ×1%
• 𝑃 𝑑𝑖𝑠𝑒𝑎𝑠𝑒 + 𝑡𝑒𝑠𝑡) = ≈ 12%
95%×1% +7%×99%