4 Probability

You might also like

Download as pdf or txt
Download as pdf or txt
You are on page 1of 99

Introduction to Probability

Outline
Basic Concepts

Rules of Probability

Conditional Probability

Contingency Tables and Probability Calculation

Case Analysis

Bayes’ Theorem
Random Experiment
• A random experiment is an action or process that leads to one of several
outcomes.
• Examples:
1. Experiment: Flip a coin.
 Outcomes: Heads and tails.
2. Experiment: Record the party that a voter will vote in an upcoming election.
 Outcomes: Party A, Party B,…
Sample Space
• A sample space of a random experiment is a list of all possible
outcomes of the experiment.
Event
• An individual outcome of a sample space is called a simple event.
• An event is a collection or set of one or more simple events in a sample space.
Probability
• A probability is a numerical value that measures the likelihood that an
uncertain event occurs.
• Requirements of Probabilities:
The probability of any outcome must lie between 0 and 1.
The sum of the probabilities of all the outcomes in a sample space must be 1.
Approaches to Assigning Probabilities
• There are three ways to assign a probability, P(Oi), to an outcome, Oi, namely:
Classical approach: Based on equally likely events.
Relative frequency: Assigning probabilities based on experimentation or
historical data.
Subjective approach: Assigning probabilities based on the assignor’s
(subjective) judgment.
Classical Approach
• If an experiment has n possible outcomes, this method would assign a
probability of 1/n to each outcome. It is necessary to determine the number of
possible outcomes.
Experiment Rolling a die
Outcomes {1, 2, 3, 4, 5, 6}
Probabilities Each sample point has a 1/6 chance of occurring.
• No matter which method is used to assign
probabilities all will be interpreted in the relative
frequency approach.
• Example: Suppose an investor have used the
subjective approach to determine that there is a
Interpreting 65% probability that a particular stock’s price will
Probability increase over the next month.
• Interpretation: If we had an infinite number of
stocks with same economic and market
characteristics as the one the investor will buy,
65% of them will increase in price over the next
month.
Probability from Relative Frequency: A
demonstration
Suppose Tata Steel is planning to increase the capacity of one
of its plants.

The project is divided into two sequential stages: Design


(stage 1) and Construction (stage 2).
Relative
Frequency Though the management wants to schedule and control each
stage as much as possible, it is impossible to predict the
Approach: An exact time required to complete each stage.
Example An analysis of 50 similar projects shows that the possible
completion times for the design stage are 2, 3 and 4 months,
and for the construction stage are 5, 6 and 7 months.

The goal is to finish the entire project in 8 months.


Relative Frequency contd..
Stage 1 Stage 2 Experimental Outcome Total Time (months)
Design Construction
2 5 (2,5) 7
2 6 (2,6) 8
2 7 (2,7) 9
3 5 (3,5) 8
3 6 (3,6) 9
3 7 (3,7) 10
4 5 (4,5) 9
4 6 (4,6) 10
4 7 (4,7) 11
Stage 1 Stage 2 Experimental No. of past
Design Construction Outcome projects Relative Frequency
2 5 (2,5) 8 contd..
2 6 (2,6) 8 • A study of 50 similar
2 7 (2,7) 6 projects is summarized in
3 5 (3,5) 6
the following table.
3 6 (3,6) 8
3 7 (3,7) 3
4 5 (4,5) 3
4 6 (4,6) 2
4 7 (4,7) 6
Sample Point Completion Time Probability
(2,5) 7 8/50 Relative Frequency
(2,6) 8 8/50 contd..
(2,7) 9 6/50 • Probability assignments
based on the previous table
(3,5) 8 6/50 can now be easily done.
(3,6) 9 8/50 • Probability of finishing the
(3,7) 10 3/50
project within 8 months is
then 22/50.
(4,5) 9 3/50
(4,6) 10 2/50
(4,7) 11 6/50
• Complement event
Basic • Intersection of events
Operations with
Events • Union of events
Basic Operations
Complement of Event Union of Events

A Ac A B

Intersection of Events

A B
Rules of Probability
Complement Rule
•The probability of the complement of an
event, 𝑃(𝐴𝐶 ), is equal to one minus the
probability of the event.
A Ac
• That is,

𝑃 𝐴𝐶 = 1 − 𝑃 𝐴 .
An Example
• According to the Census, 37% of women ages 25 to 34 have earned at least a
college degree as compared with 30% of men in the same age group.
a. What is the probability that a randomly selected woman between the ages
of 25 to 34 does not have a college degree?
b. What is the probability that a randomly selected man between the ages of
25 to 34 does not have a college degree?
Example contd..
a. Let’s define A as the event that a randomly selected woman between the
ages of 25 and 34 has a college degree.
Then 𝑃(𝐴) = 0.37.
In this problem, we are interested in the complement of A.
So 𝑃(𝐴𝐶 ) = 1 – 𝑃(𝐴) = 1 – 0.37 = 0.63.
Example contd..
b. We now define B as the event that a randomly selected man between the
ages of 25 to 34 has a college degree.
So 𝑃(𝐵) = 0.30.
Thus 𝑃 𝐵𝐶 = 1 − 𝑃 𝐵 = 1 − 0.30 = 0.70.
Addition Rule
• The probability that event A or B A∩B
occurs, or that at least one of these
events occurs, is

P(A ∪ B) = P(A) + P(B) – P(A ∩ B). A B

A∪B
An Example
• Anthony feels that he has a 75% chance of getting an A in Statistics and a 55%
chance of getting an A in Managerial Economics. He also believes he has a 40%
chance of getting an A in both classes.
What is the probability that he gets an A in at least one of these courses?
What is the probability that he does not get an A in either of these courses?
Example contd..
• AS : Getting an A in Statistics.
• AM: Getting an A in Managerial Economics.
• Given P(AS) = 0.75 and P(AM) = 0.55 and P(AS ∩ AM) = 0.40.
• In order to find the probability that he receives an A in at least one
of these courses, we calculate:
P(AS ∪ AM) = 𝑃(AS) + 𝑃(AM) – 𝑃(AS ∩ AM)
= 0.75 + 0.55 – 0.40 = 0.90.
Example contd..
• The probability that he does not receive an A in either of these two
courses is actually the complement of the union of the two events;
that is, P((AS ∪ AM)c).
• Using the complement rule, we have

𝑃((AS ∪ AM)𝑐 ) = 1 – 𝑃(AS ∪ AM)


= 1 – 0.90 = 0.10.
Addition Rule for Two Mutually Exclusive Events

𝑃(𝐴 ∩ 𝐵) = 0

A B

A∪B
P(A ∪ B) = P(A) + P(B)
An Example
• Samantha Greene, a college senior, contemplates her future immediately after
graduation. She thinks there is a 25% chance that she will join the Peace Corps
and a 35% chance that she will enroll in a full-time law school program in the
United States.
• What is the probability that she does not choose either of these options?
An Example
• Samantha Greene, a college senior, contemplates her future
immediately after graduation. She thinks there is a 25% chance that
she will join the Peace Corps and a 35% chance that she will enroll in
a full-time law school program in the United States.
• What is the probability that she does not choose either of these
options?

P(A ∪ B) = P(A) + P(B) = 0.25 + 0.35 = 0.60

P((A ∪ B)c) = 1 – P(A ∪ B) = 1 – 0.60 = 0.40


Unconditional (Marginal) Probability
• The probability of an event without any restriction.
• For example, P(A) = probability of finding a job, and P(B) = probability of
prior work experience.
Conditional Probability
• The probability of an event given that another event has already
occurred.
 In the conditional probability statement, the symbol “ | ” means
“given.”
 Whatever follows “ | ” has already occurred.

• For example, P(A) = probability of finding a job, and P(B) = probability


of prior work experience.
 For example, P(A | B) = probability of finding a job given prior
work experience.
Conditional Probability

A∩B If B has already occurred,


the relevant portion of
the sample space
A B reduces to B.
Calculating a Conditional Probability
• Given two events A and B, each with a positive probability of occurring, the
probability that A occurs given that B has occurred, is equal to

𝑃 𝐴∩𝐵
P (A | B) =
𝑃(𝐵)
An Example
• An economist predicts a 60% chance that country A will perform poorly
economically and a 25% chance that country B will perform poorly economically.
There is also a 16% chance that both countries will perform poorly. What is the
probability that country A performs poorly given that country B performs
poorly?
An Example
• An economist predicts a 60% chance that country A will perform poorly
economically and a 25% chance that country B will perform poorly economically.
There is also a 16% chance that both countries will perform poorly. What is the
probability that country A performs poorly given that country B performs
poorly?
• Given P(A) = 0.60, P(B) = 0.25, and P(A ∩ B) = 0.16.

𝑃 𝐴 ∩𝐵 0.16
P (A | B) = 𝑃(𝐵)
=
0.25
= 0.64
Independent Events
• Two events are independent if the occurrence of one event does not affect
the probability of the occurrence of the other event.
• Events are considered dependent if the occurrence of one is related to the
probability of the occurrence of the other.
• Two events are independent if and only if

P  A | B   P  A
An Example
• Suppose that for a given year there is a 2% chance that your desktop computer
will crash and a 6% chance that your laptop computer will crash. Moreover,
there is a 0.12% chance that both computers will crash. Is the reliability of the
two computers independent of each other?
Example contd..
• D: Desktop crashes
• L: Laptop crashes.
• P(D) = 0.02, P(L) = 0.06, and P(D ∩ L) = 0.0012.
• The reliability of the two computers is independent because
𝑃(𝐷 ∩ 𝐿) 0.0012
𝑃 𝐷𝐿 = = = 0.02 = P D .
𝑃(𝐿) 0.06
Multiplication Rule
• The probability that A and B both occur is equal to:

P(A ∩ B) = P(A | B) × P(B)


= P(B | A) × P(A)

• Note that when two events are mutually exclusive


P(A ∩ B) = 0
An Example
• A stockbroker knows from past experience that the probability that a client
owns stocks is 0.60 and the probability that a client owns bonds is 0.50. The
probability that the client owns bonds if he/she already owns stocks is 0.55.
What is the probability that the client owns both of these securities?
Given that the client owns bonds, what is the probability that the client owns
stocks?
Example contd..
• S: Event that a client owns stocks
• B : Event that a client owns bonds.
• Given P(S) = 0.60, P(B) = 0.50, P(B | S) = 0.55.
• We calculate the probability that the client owns both of these
securities as
𝑃(𝑆 ∩ 𝐵) = 𝑃(𝐵 | 𝑆)𝑃(𝑆) = 0.55 × 0.60 = 0.33.
Example contd..
• Next, we need to calculate the conditional probability that the client
owns stocks given that he/she owns bonds, or P(S | B).

𝑃(𝑆 ∩ 𝐵) 0.33
𝑃 𝑆𝐵 = = = 0.66.
𝑃(𝐵) 0.50
Multiplication Rule for Independent Events
• The joint probability of A and B equals the product of the individual
probabilities of A and B:

P(A ∩ B) = P(A)P(B)

• This multiplication rule may also be used to determine


independence.
Example
• The probability of passing the Level 1 CFA (Chartered Financial Analyst) exam is
0.50 for John Campbell and 0.80 for Linda Lee. The prospect of John’s passing
the exam is completely unrelated to Linda’s success on the exam.
What is the probability that both John and Linda pass the exam?
What is the probability that at least one of them passes the exam?
Example contd..
• J: John passes the exam
• L: Linda passes the exam
• Given P(J) = 0.50 and P(L) = 0.80, and L and J are independent.

a. 𝑃 𝐽 ∩ 𝐿 = 𝑃 𝐽 × 𝑃 𝐿 = 0.50 × 0.80 = 0.40.


b. 𝑃 𝐽 ∪ 𝐿 = 𝑃 𝐽 + 𝑃 𝐿 − 𝑃 𝐽 ∩ 𝐿
= 0.50 + 0.80 − 0.40 = 0.90
Case: 24/7 Fitness Center Annual Membership
Case: 24/7 Fitness Center Annual Membership
• 24/7 Fitness Center is a high-end, full-service gym and recruits its members through
advertisements and monthly open house events.
• Each open house attendee is given a tour and one-day pass.
• Potential members register for the open house event by answering a few questions
about themselves and their exercise routine.
• The fitness center staff places a follow-up phone call with the potential member and
sends information to the open house attendees by mail in the hopes of signing the
potential member up for an annual membership.
Case: 24/7 Fitness Center
Annual Membership
• A manager at 24/7 Fitness Center wants to
develop a data-driven strategy for selecting
which new open house attendees to contact.
• Data are available from 400 past open house
attendees.
Case: 24/7 Fitness Center Annual Membership
• Using the sample information:
a. Construct a contingency table and use it to calculate and interpret relevant empirical
probabilities concerning age and enrollment.
b. Use the empirical probabilities to develop a data-driven strategy for selecting open
house attendees.
Contingency Table
•A contingency table is useful when
Age Group examining the relationship between two
Outcome Under Between 30 Over 50 categorical variables.
30 (U) and 50 (B) (O) • It shows the frequencies for two categorical
variables, X and Y.
Enrol (E)
Not Enrol
• Each cell represents a mutually exclusive
(N)
combination of the pair of X and Y values.
• We can estimate an empirical probability by
calculating the relative frequency of the
occurrence of the event.
Contingency Table
Age Group
Outcome Under 30 (U) Between 30 and 50 (B) Over 50 (O) Total

Enrol (E) 24 72 44 140


Not Enrol (N) 84 88 88 260
Total 108 160 132 400
Converting a Contingency Table to a Joint
Probability Table
Age Group
Outcome Under 30 (U) Between 30 and 50 (B) Over 50 (O) Total

Enrol (E) 0.06 0.18 0.11 0.35


Not Enrol (N) 0.21 0.22 0.22 0.65
Total 0.27 0.40 0.33 1.00
Case Questions
• What is the probability that a randomly selected attendee enrolls in the fitness
center?
• What is the probability that a randomly selected attendee is over 50 years old?
• What is the probability that a randomly selected attendee enrolls in the fitness
center and is over 50 years old?
• What is the probability that an attendee enrolls in the fitness center, given the
attendee is over 50 years old?
Case Solutions
Age Group • What is the probability that a
Outcome Total randomly selected attendee enrolls in
Under Between Over 50
30 (U) 30 and 50 (O) the fitness center?
(B)
Enrol (E) 0.06 0.18 0.11 0.35

Not Enrol 0.21 0.22 0.22 0.65


(N)

Total 0.27 0.40 0.33 1.00


Case Solutions
Age Group • What is the probability that a
Outcome
Under Between Over 50
Total randomly selected attendee enrolls in
30 (U) 30 and 50 (O) the fitness center?
(B)
• The required probability is given by
Enrol (E) 0.06 0.18 0.11 0.35
𝑃 𝐸 = 0.35
Not Enrol 0.21 0.22 0.22 0.65
(N)

Total 0.27 0.40 0.33 1.00


Case Solutions
Age Group • What is the probability that a
Outcome Total randomly selected attendee is over 50
Under Between Over 50
30 (U) 30 and 50 (O) years old?
(B)
Enrol (E) 0.06 0.18 0.11 0.35

Not Enrol 0.21 0.22 0.22 0.65


(N)

Total 0.27 0.40 0.33 1.00


Case Solutions
Age Group • What is the probability that a
Outcome Total randomly selected attendee is over 50
Under Between Over 50
30 (U) 30 and 50 (O) years old?
(B)
• The required probability is given by
Enrol (E) 0.06 0.18 0.11 0.35

Not Enrol 0.21 0.22 0.22 0.65


𝑃 𝑂 = 0.33
(N)

Total 0.27 0.40 0.33 1.00


Case Solutions
Age Group • What is the probability that a
Outcome Total randomly selected attendee enrolls in
Under Between Over 50
30 (U) 30 and 50 (O) the fitness center and is over 50 years
(B) old?
Enrol (E) 0.06 0.18 0.11 0.35

Not Enrol 0.21 0.22 0.22 0.65


(N)

Total 0.27 0.40 0.33 1.00


Case Solutions
Age Group • What is the probability that a
Outcome Total randomly selected attendee enrolls in
Under Between Over 50
30 (U) 30 and 50 (O) the fitness center and is over 50 years
(B) old?
Enrol (E) 0.06 0.18 0.11 0.35
• The required probability is given by
Not Enrol 0.21 0.22 0.22 0.65
(N) 𝑃 𝐸 ∩ 𝑂 = 0.11

Total 0.27 0.40 0.33 1.00


Case Solutions
Age Group • What is the probability that an
Outcome Total attendee enrolls in the fitness center,
Under Between Over 50
30 (U) 30 and 50 (O) given the attendee is over 50 years
(B) old?
Enrol (E) 0.06 0.18 0.11 0.35

Not Enrol 0.21 0.22 0.22 0.65


(N)

Total 0.27 0.40 0.33 1.00


Case Solutions
Age Group • What is the probability that an
Outcome Total attendee enrolls in the fitness center,
Under Between Over 50
30 (U) 30 and 50 (O) given the attendee is over 50 years
(B) old?
Enrol (E) 0.06 0.18 0.11 0.35
• The required probability is given by
Not Enrol 0.21 0.22 0.22 0.65 𝑃(𝐸 ∩ 𝑂) 0.11 1
(N) 𝑃 𝐸|𝑂 = = =
𝑃(𝑂) 0.33 3
Total 0.27 0.40 0.33 1.00
Case Questions
• Calculate the conditional probabilities of enrolling in the fitness centre for the
different age groups.
• Is age related to enrolment? Explain using probabilities.
Case Solutions
Age Group • Calculate the conditional probabilities
Outcome Total of enrolling in the fitness centre for the
Under Between Over 50
30 (U) 30 and 50 (O) different age groups.
(B)
Enrol (E) 0.06 0.18 0.11 0.35

Not Enrol 0.21 0.22 0.22 0.65


(N)

Total 0.27 0.40 0.33 1.00


Case Solutions
Age Group d. Calculate the conditional
Outcome Total probabilities of enrolling in the fitness
Under Between Over 50
30 (U) 30 and 50 (O) centre for the different age groups.
(B)
• The required probabilities are given
Enrol (E) 0.06 0.18 0.11 0.35
by
Not Enrol 0.21 0.22 0.22 0.65 𝑃(𝐸 ∩ 𝑈) 0.06
𝑃 𝐸𝑈 = = = 0.22
(N) 𝑃(𝑈) 0.27
𝑃(𝐸 ∩ 𝐵) 0.18
Total 0.27 0.40 0.33 1.00 𝑃 𝐸𝐵 = = = 0.45
𝑃(𝐵) 0.40
𝑃(𝐸 ∩ 𝑂) 0.11
𝑃 𝐸𝑂 = = = 0.33
𝑃(𝑂) 0.33
Case Solutions
Age Group • Is age related to enrolment? Explain using
Outcome Total probabilities.
Under Between Over 50
30 (U) 30 and 50 (O)
(B)
Enrol (E) 0.06 0.18 0.11 0.35

Not Enrol 0.21 0.22 0.22 0.65


(N)

Total 0.27 0.40 0.33 1.00


Case Solutions
Age Group •Is age related to enrolment? Explain using
Outcome Total probabilities.
Under Between Over 50
30 (U) 30 and 50 (O) • IfAge and Enrolment were independent,
(B)
then
Enrol (E) 0.06 0.18 0.11 0.35 𝑃 𝐸𝑈 =𝑃 𝐸𝐵 =𝑃 𝐸𝑂 =𝑃 𝐸 .
• In other words, the probability of
Not Enrol 0.21 0.22 0.22 0.65
enrolment will not be impacted by the age
(N)
of the attendees.
Total 0.27 0.40 0.33 1.00
• Because the conditional probabilities
differ from 𝑃(𝐸), we can conclude that age
and enrolment are not independent.
Back to Case 2: Finding Right Customers
For Royal Credit Card
Case 2: Finding Right Customers at Easy
Credit

Overview Challenge Objective


Royal Bank is a well-known A number of Royal credit card Royal Bank wants to re-examine
name in India. holders are students. the strategy of issuing credit
It provides easy access to its cards to students.
credit cards.
Default Data Set
A data set on ten thousand customers.

Variables

• Default: A factor with levels “No” and “Yes” indicating whether the customer
defaulted on their debt.
• Student: A factor with levels “No” and “Yes” indicating whether the customer is a
student.
• Balance: The average balance that the customer has remaining on their credit card
after making their monthly payment.
• Income: Income of customer.
Default Data Set
ID Balance Income Student Default
1 729.52 44361.63 No No
2 817.18 12106.13 Yes No
3 1073.55 31767.14 No No
4 529.25 35704.49 No No
5 785.66 38463.5 No No
6 919.59 7491.559 Yes No
7 825.5 24905.23 No No
8 808.67 17600.45 Yes No
9 1161.06 37468.53 No No
Revisit to Case 2..
Student
Default Total
No Yes

No 6850 2817 9667

Yes 206 127 333

Total 7056 2944 10000


Case 2 contd..
Student
Default No Yes Total

No 6850 2817 9667


Yes 206 127 333
Total 7056 2944 10000

1. What is the probability that a randomly selected person will default?


2. What is the probability that a randomly selected student will default?
3. Are the students more risky as compared to all customers who are not
students?
Case 2 contd..
Student
Default No Yes Total

No 6850 2817 9667


Yes 206 127 333
Total 7056 2944 10000

1. What is the probability that a randomly selected person will default?


333
Pr Default = = 3.33%
10000
Case 2 contd..
Student
Default No Yes Total

No 6850 2817 9667


Yes 206 127 333
Total 7056 2944 10000

2. What is the probability that a randomly selected student will default?

𝑃(Default ∩ Student) 127


Pr Default Student = = = 4.31%.
𝑃(Student) 2944
Case 2 contd..
Student
Default No Yes Total

No 6850 2817 9667


Yes 206 127 333
Total 7056 2944 10000

2. What is the probability that a randomly selected student will default?

𝑃(Default ∩ Student) 127


Pr Default Student = = = 4.31%.
𝑃(Student) 2944
Case 2 contd..
Student
Default No Yes Total

No 6850 2817 9667


Yes 206 127 333
Total 7056 2944 10000

3. Are the students more risky as compared to all customers who are not
students?
𝑃(Default ∩ Not Student) 206
Pr Default Not Student = = = 2.92%.
𝑃(Not Student) 7056
Total Probability
Total Probability
B c Consider event 𝐵 and its complement
B A

𝑐
𝐵 .
These two events are mutually exclusive

and exhaustive.
•The circle, representing event A,
consists 𝑐entirely of its intersections with
𝐵 and 𝐵 .
P(A ∩ B) P(A ∩ Bc) •𝑃(𝐴) is the sum of its intersections with
some mutually exclusive and exhaustive
events corresponding to an experiment.
Total Probability
• The total probability rule conditional on two events, B and Bc, is

P(A) = P(A ∩ B) + P(A ∩ Bc)


or equivalently,

P(A) = P(A | B)P(B) + P(A | Bc)P(Bc)


Example
• Even though a certain statistics professor does not require attendance as part of
a student’s overall grade, she has noticed that those who regularly attend class
have a higher tendency to get a final grade of A.
• The professor calculates that there is an 80% chance that a student attends
class regularly.
• Moreover, given that a student attends class regularly, there is a 35% chance
that the student receives an A grade; however, if a student does not attend class
regularly, there is only a 5% chance of an A grade.
•Use this information to answer the following questions.
Example contd..
• What is the probability that a student does not attend class regularly?
• What is the probability that a student attends class regularly and receives an A
grade?
• What is the probability that a student does not attend class regularly and
receives an A grade?
• What is the probability that a student receives an A grade?
Probability Tree
Tabular Method
Unconditional Conditional Probability Joint Probability
Probability
𝑃 𝑅 = 0.80 𝑃 𝐴 𝑅 = 0.35 𝑃 𝐴∩𝑅
= 𝑃 𝐴 𝑅 𝑃 𝑅 = 0.28

𝑃 𝑅𝑐 = 0.20 𝑃 𝐴 𝑅𝑐 = 0.05 𝑃 𝐴 ∩ 𝑅𝑐
= 𝑃 𝐴 𝑅𝑐 𝑃 𝑅𝑐
= 0.01
𝑃 𝑅 + 𝑃 𝑅𝑐 = 1.00 𝑃 𝐴
=𝑃 𝐴∩𝑅
+ 𝑃 𝐴 ∩ 𝑅𝑐 = 0.29
Example contd..
1. 𝑃 𝑅𝑐 = 0.20.
2. 𝑃 𝐴 ∩ 𝑅 = 𝑃 𝐴 𝑅 𝑃 𝑅 = 0.28
3. 𝑃 𝐴 ∩ 𝑅𝑐 = 𝑃 𝐴 𝑅𝑐 𝑃 𝑅𝑐 = 0.01
4. 𝑃 𝐴 = 𝑃 𝐴 ∩ 𝑅 + 𝑃 𝐴 ∩ 𝑅𝑐 = 0.29
Bayes’
Theorem
Bayes’ Theorem
• Suppose that a person is worried that he might have a rare disease.
• He decides to get tested, and suppose that the testing methods for this disease
are correct 99 percent of the time (in other words, if he has the disease, it shows
that he does with 99 percent probability, and if he doesn't have the disease, it
shows that he does not with 99 percent probability).
• Suppose this disease is actually quite rare, occurring randomly in the general
population in only one of every 10,000 people.
• If the test results come back positive, what are his chances that he actually has
the disease?
Bayes’ Theorem
Test Results
True Positive Negative Total
Status Disease
No Disease
Total 10,00,000
Bayes’ Theorem
Test Results
True Positive Negative Total
Status Disease 100
No Disease 99,99,00
Total 1,000,000
Bayes’ Theorem
Test Results
True Positive Negative Total
Status Disease 99 1 100
No Disease 99,99,00
Total 1,000,000
Bayes’ Theorem
Test Results
True Positive Negative Total
Status Disease 99 1 100
No Disease 9999 989901 99,99,00
Total 1,000,000
Bayes’ Theorem
Test Results
True Positive Negative Total
Status Disease 99 1 100
No Disease 9999 989901 99,99,00
Total 10098 989902 1,000,000
Bayes’ Theorem
Test Results
True Positive Negative Total
Status Disease 99 1 100
No Disease 9999 989901 99,99,00
Total 10098 989902 1,000,000

99
𝑃 𝐷𝑖𝑠𝑒𝑎𝑠𝑒 𝑃𝑜𝑠𝑖𝑡𝑖𝑣𝑒 = = 0.0098 < 1%.
10098
Bayes’ Theorem
Bayes’ Theorem
• A procedure for updating probabilities based on new information.
• Prior probability is the original (unconditional) probability (e.g., P(B) ).
• Posterior probability is the updated (conditional) probability (e.g., P(B | A)).
• In its most basic form, if we know 𝑃(𝐴 | 𝐵), we can apply Bayes’ Law to
determine 𝑃(𝐵 |𝐴).
Bayes’ Theorem
• Given a set of prior probabilities for an event and some new information, the rule for
updating the probability of the event is called Bayes’ theorem.

P(A ∩ B)
P(B | A) =
P(A ∩ B) + P(A ∩ Bc)

P(A | B)P(B)
P(B | A) =
P(A | B)P(B) + P(A | Bc)P(Bc)
Example
• In a lie-detector test, an individual is asked to answer a series of questions while
connected to a polygraph (lie detector).
• This instrument measures and records several physiological responses of the
individual on the basis that false answers will produce distinctive
measurements.
• Assume that 99% of the individuals who go in for a polygraph test tell the truth.
• These tests are considered to be 95% reliable. In other words, there is a 95%
chance that the test will detect a lie if an individual actually lies.
Example contd..
• Let there also be a 0.5% chance that the test erroneously detects a lie even
when the individual is telling the truth.
• An individual has just taken a polygraph test and the test has detected a lie.
• What is the probability that the individual was actually telling the truth?
Example contd..
• Let D denote the outcome that the polygraph detects a lie and T represent the
outcome that an individual is telling the truth.
• Given 𝑃(𝑇) = 0.99. This implies 𝑃 𝑇 𝑐 = 0.01.
• Also 𝑃 𝐷 𝑇 𝑐 = 0.95 and 𝑃 𝐷 𝑇 = 0.005.
• We have to find out 𝑃 𝑇 𝐷 .
Computing Posterior Probabilities

P(D ∩ T)
P(T | D) =
P(D ∩ T) + P(D ∩𝑇 𝑐 )
(0.005)(0.99) 0.00495
= =
(0.005)(0.99) + (0.95)(0.01) 0.01445
= 0.34256
Reading Material
• Sections 4.1, 4.2, 4.3 and 4.4
• Additional Questions and Cases uploaded in VC

You might also like