Lecture 3 - Probability Final
Lecture 3 - Probability Final
PROBABILITY
DISTRIBUTIONS
ENS185 2nd Semester
Introduction to Data Analysis 2
PROCESS OF STATISTICS
Identify the A researcher must determine the questions he or she want answered. The
research objective questions must clearly identify the population that is to be studied.
Collect the data Conducting the data on the whole population is impractical and expensive.
However, appropriate data collection techniques must also be followed.
needed
Describe the Describe the data collected using numerical and visual tools. It gives us an
overview of the data and can help us determine which statistical tools to use
data for inference.
Perform Apply the appropriate techniques to extend the results obtained from the
sample to the population and report a level of reliability of the results.
inference
3
Probability Rules
Addition Rule and Complements
Independence and Multiplication Rule
Conditional Probability
Counting Techniques
PROBABILITY RULES
Probability 9
PROBABILITY
The probability of an outcome is the likelihood of observing that outcome.
PROBABILITY
In probability, an experiment is any process with uncertain results that can be
repeated. However, the results of the experiment over many trials produce regular
patterns that allow accurate predictions.
EXAMPLE
Problem: A probability experiment consists of
rolling a single fair die.
(a) Identify the outcomes of the probability
experiment.
(b) Determine the sample space.
(c) Define the event E=“roll an even number.”
Presentation title 12
ANSWERS
(a) Identify the outcomes of the probability
experiment.
Possible outcomes include 1,2,3,5,6
(b) Determine the sample space.
𝑺 = 𝟏, 𝟐, 𝟑, 𝟒, 𝟓, 𝟔
(c) Define the event E=“roll an even number.”
𝑬 = {𝟐, 𝟒, 𝟔}
Probability 13
RULES OF PROBABILITY
1. The probability of any event E, P(E), must be greater than or equal to 0 and less
than or equal to 1. That is, 0 ≤ 𝑃 𝐸 ≤ 1.
2. The sum of all probabilities of all outcomes must equal 1. That is, if the sample
space S
PROBABILITY
If an event is impossible, its probability is zero. If an event is certain, its probability is
1.
An unusual event is an event that has a low probability of occurring. The typical
cutoff point is 0.05. If the probability of an event occurring is less than 0.05, it is
considered unusual. However, this is not a fixed cutoff point.
Probability 15
APPROACHES OF PROBABILITY
Empirical method
The probability of an event E is approximately the number of times event E is
observed divided by the number of repetitions of the experiment.
𝑓𝑟𝑒𝑞𝑢𝑒𝑛𝑐𝑦 𝑜𝑓 𝐸
𝑃 𝐸 =
𝑛𝑢𝑚𝑏𝑒𝑟 𝑜𝑓 𝑡𝑟𝑖𝑎𝑙𝑠
EXAMPLE
75 girls were born out of 100 births. Therefore, P(girl)=75/100=0.75
Probability 17
APPROACHES OF PROBABILITY
Classical method
If an experiment has n equally likely outcomes and if the number of ways that an
event E can occur is m, then the probability of E, P(E), is
𝑛𝑢𝑚𝑏𝑒𝑟 𝑜𝑓 𝑤𝑎𝑦𝑠 𝐸 𝑐𝑎𝑛 𝑜𝑐𝑐𝑢𝑟 𝑚
𝑃 𝐸 = =
𝑛𝑢𝑚𝑏𝑒𝑟 𝑜𝑓 𝑝𝑜𝑠𝑠𝑖𝑏𝑙𝑒 𝑜𝑢𝑡𝑐𝑜𝑚𝑒𝑠 𝑛
So, if S is the sample space of this experiment,
𝑁(𝐸)
𝑃 𝐸 =
𝑁(𝑆)
EXAMPLE
If a fair dice is rolled, what is the probability of getting an even number?
Probability 18
APPROACHES OF PROBABILITY
Subjective probability of an outcome is a probability obtained on the basis of
personal judgment. It is important to understand that subjective probabilities are
perfectly legitimate and are often the only method of assigning likelihood to an
outcome.
EXAMPLE
Economists may be asked about the likelihood the economy will go into recession or not.
Probability 19
IMPORTANT TERMS
An event is a subset of the sample
space. 5
For example, if we toss a dice.
2
B
𝑆 = 1,2,3,4,5,6
An example of an event 1 4
Let E=event that the result is an even 6
number
𝐵 = 2,4,6
And thus, B is a subset of S. 3
S
Probability 20
IMPORTANT TERMS
The complement of an event A with
respect to S is the subset of all 5
elements of S that are not in A. We
denote the complement of A by the
2
symbol A’
1 B 4
𝑃 𝐴 + 𝑃 𝐴′ = 1 6
B’={1,3,5}
B’ 3
S
Probability 21
IMPORTANT TERMS
The intersection of two events A and 1
B is the event containing all elements
common to A and B.
𝐴∩𝐵 5 4
2 B
Example:
A 6
Let A= number greater than 3
𝐴 = {4,5,6}
B= event numbers
𝐵 = {2,4,6} 3
Therefore,
S
𝐴 ∩ 𝐵 = {4,6}
Probability 22
IMPORTANT TERMS
The union of two events A and B is the 1
event containing all elements that
belong to A or B or both
6 B
𝐴∪𝐵
2
4
Example:
Let A= number greater than 3
A 5
𝐴 = {4,5,6}
B= event numbers
𝐵 = {2,4,6}
Therefore, 3
𝐴 ∪ 𝐵 = {2,4,5,6}
S
Probability 23
IMPORTANT TERMS
Disjoint or mutually exclusive
events are two events that cannot
occur at the same time.
1
3
6 B
𝐴 ∩ 𝐵 = ∅ = {}
5
4
Example:
Let A= even numbers
A
𝐴 = {2,4,6} 2
B= odd numbers
𝐵 = {1,3,5}
Therefore,
𝐴 ∩ 𝐵 = {}
S
Presentation title 24
EXAMPLE
A class contains 100 students; 70 of them like
mathematics, 60 like physics, and 40 like both. If a student
is chosen at random, using a Venn diagram, find the
probability that they like mathematics only.
Presentation title 25
ANSWER
Begin by drawing a Venn diagram,
70-40=30 40 60-40=20
100-40-30-20=10
Presentation title 26
ANSWER
The area of interest is shown below,
P(mathematics only)=30/100=0.30
Presentation title 27
EXAMPLE
A gene is composed of two alleles, either dominant or
recessive. Suppose that a husband and wife, who are both
carriers of the sickle-cell anemia allele but do not have the
disease, decide to have a child. Because both parents are
carriers of the disease, each has one dominant normal-cell
allele (S) and one recessive sickle-cell allele (s). Therefore,
the genotype of
each parent is Ss. Each parent contributes one allele to his
or her offspring, with each allele being equally likely.
a) List the possible genotypes of their offspring.
Presentation title 29
EXAMPLE
Possible Outcomes:
𝑺 = 𝑺𝑺, 𝑺𝒔, 𝑺𝒔, 𝒔𝒔
Presentation title 30
EXAMPLE
What is the probability that the offspring will have sickle
cell anemia?
𝑛{𝑠𝑠} 1
𝑃= =
𝑛 𝑡𝑜𝑡𝑎𝑙 4
Presentation title 31
EXAMPLE
What is the probability that the offspring will not have
sickle-cell anemia but will be a carrier?
𝑛{𝑆𝑠, 𝑆𝑠} 2 1
𝑃= = =
𝑛 𝑡𝑜𝑡𝑎𝑙 4 2
Presentation title 32
EXAMPLE
If you roll a 6-sided dice, what is the probability of getting
an even number?
a) 1/6
b) 1/3
c) 1/2
d) 5/6
Presentation title 33
𝑷 𝑨 ∪ 𝑩
𝑷 𝑨 𝑷 𝑩 𝑷 𝑨 ∩𝑩
= + −
𝑷 𝑨 ∪ 𝑩
𝑷 𝑨 𝑷 𝑩 𝑷 𝑨 ∩𝑩
= + −
COMPLEMENT RULE
Two events are disjoint if they have no outcomes in common. Another name for
disjoint events is mutually exclusive events.
EXAMPLE
An African Safari touring company claims
that on the tour the probability you will see
a giraffe is 75%, an elephant is 65% and the
probability you will see both a giraffe and
an elephant is 55%.
What is the probability you see either a
giraffe or elephant or both?
Presentation title 41
ANSWER
Let G= seeing a giraffe, E=seeing an
elephant where P(G)=0.75, P(E)=0.65,
𝑃 𝐺 ∩ 𝐸 = 0.55
Find: 𝑃 𝐺 ∪ 𝐸
𝑃 𝐺∪𝐸 =𝑃 𝐺 +𝑃 𝐸 −𝑃 𝐺∩𝐸
𝑃 𝐺 ∪ 𝐸 = 0.75 + 0.65 − 0.55 = 0.85
Presentation title 42
a) 0.19
b) 0.59
c) 0.40
d) 0.29
INDEPENDENT EVENTS
Probability 45
INDEPENDENT EVENTS
Two events E and F are independent if the occurrence of event E in
probability experiment does not affect the probability of event F. Two events
are dependent if the occurrence of event E in a probability experiment affects
the probability of event F.
QUESTIONS?
1. Suppose you flip a coin and roll a dice. Are the two events independent?
2. Event A: Earned a bachelor’s degree; Event B: earn at least P30,000 per month
MULTIPLICATION RULE
If and only if A and B are independent, the Multiplication Rule for Independent
Events can be used to find the intersection between two events.
𝑃 𝐴∩𝐵 =𝑃 𝐴 ×𝑃 𝐵
EXAMPLE
In the game of roulette, the wheel has slots
numbered 0, 00, and 1 through 36. A metal
ball rolls around a wheel until it falls into
one of the numbered slots. What is the
probability that the ball will land in the slot
numbered 17 two times in a row?
Presentation title 48
ANSWER
There are 38 possible outcomes. Using the
classical method, the probability of landing
in 17 is 1/38.
a) 39%
b) 11%
c) 8%
d) 32%
Presentation title 50
CONDITIONAL PROBABILITY
The notation 𝑃 𝐹 𝐸 is read “the probability of event F given event E.” It is the
probability that the event F occurs, given that the event E has occurred.
𝑃(𝐹 ∩ 𝐸)
𝑃 𝐹𝐸 =
𝑃(𝐸)
Conditional probabilities redefine the sample space to include only events that
are in the conditional subset E.
Probability 53
EXAMPLE
A recent study from Pew Research Center
indicates 77% of adults in the United States use a
smartphone (SP) to access the internet, while
65% access the internet at home with a
broadband (BB) service and 52% access with
both a smartphone and broadband. Given
someone accesses the internet with broadband,
what is the chance they also access the internet a
smartphone?
Probability 54
SOLUTION
Let
S= event someone uses a smartphone
B= event someone uses a broadband
P(S)=0.77, P(B)=0.65, P(S and B)=0.52
Find 𝑃 𝑆 𝐵
𝑃(𝑆 ∩ 𝐵) 0.52
𝑃 𝑆𝐵 = =
𝑃(𝐵) 0.65
Probability 55
BAYES’ THEOREM
can be used to find a conditional probability when only other conditional
probabilities are known. The formula is a combination the Law of Total
Probability and the Multiplication Rule.
𝑃(𝐴 ∩ 𝐵) 𝑃(𝐴) × 𝑃 𝐵 𝐴
𝑃 𝐴𝐵 = =
𝑃(𝐵) 𝑃 𝐴 × 𝑃 𝐵 𝐴 + 𝑃(𝐴′ ) × 𝑃 𝐵 𝐴′
Probability 57
EXAMPLE
A doctor is called to see a sick child. The doctor has prior information that 90% of
sick children in that neighborhood have the flu, while the other 10% are sick with
measles. Let F stand for an event of a child being sick with flu and M stand for an
event of a child being sick with measles.
A well-known symptom of measles is a rash. Assume that the probability of having
a rash if one has measles is 0.95. However, occasionally children with flu also
develop rash, and the probability of having a rash if one has flu is 0.08.
Upon examining the child, the doctor finds a rash. What is the probability that the
child has measles?
Probability 58
ANSWER
Let F= a child has flu, M= a child has measles, R= occurrence of measles
Find 𝑃 𝑀 𝑅
𝑃(𝑀 ∩ 𝑅)
𝑃 𝑀𝑅 =
𝑃(𝑅)
𝑃(𝑀 ∩ 𝑅)
𝑃 𝑀𝑅 =
𝑃 𝑀 ∩ 𝑅 + 𝑃(𝐹 ∩ 𝑅)
𝑃 𝑀 𝑃 𝑅𝑀
𝑃 𝑀𝑅 =
𝑃 𝑀 𝑃 𝑅 𝑀 +𝑃 𝐹 𝑃 𝑅 𝐹
0.10(0.95)
𝑃 𝑀𝑅 =
0.10(0.95) + 0.90(0.08)
𝑃 𝑀 𝑅 = 0.5688
Probability 59
ANSWER
Another way of solving these types of problem is by creating a contingency
table.
ANSWER
Therefore,
𝑃(𝑀 ∩ 𝑅) 9.5
𝑃 𝑀𝑅 = = = 0.5688
𝑃(𝑅) 16.7
Tip: You may use either of the two illustrations whichever you are more
comfortable with.
Probability 61
VENN DIAGRAMS
Venn diagrams can be used to represents events and sample spaces. Let the circles
enclosed in the rectangle be an event. The rectangle is the sample space.
Event
M
M and I
Event
I
Not M nor I
Probability 64
EXAMPLE
A recent study from Pew Research Center indicates 77% of adults in the United
States use a smartphone (S) to access the internet, while 65% access the internet at
home with a broadband (B) service and 52% access with both a smartphone and
broadband. Draw the Venn diagram.
Not S nor B
Probability 65
EXAMPLE
A recent study from Pew Research Center indicates 77% of adults in the United
States use a smartphone (S) to access the internet, while 65% access the internet at
home with a broadband (B) service and 52% access with both a smartphone and
broadband
S
0.25
S and B
0.52
Event
0.13 I
CONTINGENCY TABLES
A table showing the distribution of one variable in rows and another in columns,
used to study the association between the two variable.
Most of the time, the contingency table is readily given but we can also create our
own based on the given information.
Contingency tables are also great for solving conditional probabilities easily.
67
67
Probability 68
SOLUTION
Assuming that 100 emails are received (you can assume 1000 or any value).
Emails Received
Account 1 Account 2 Account 3 Total
Spam 50(0.10)=5 30(0.30)=9 20(0.80)=16 30
Not Spam 50(1-0.10)45 30(1-0.30)=21 20(1-0.80)=4 70
100(0.50)= 100(0.30)= 100(0.20)= 100
50 30 20
Emails Received
Account 1 Account 2 Account 3 Total
Spam 50(0.10)=5 30(0.30)=9 20(0.80)=16 30
Not Spam 50(1-0.10)45 30(1-0.30)=21 20(1-0.80)=4 70
100(0.50)= 100(0.30)= 100(0.20)= 100
50 30 20
𝑛 1 ∩ 𝑆′ 45
𝑃 𝑆′ 1 = = = 0.90
𝑛 1 50
69
70
Emails Received
Account 1 Account 2 Account 3 Total
Spam 50(0.10)=5 30(0.30)=9 20(0.80)=16 30
Not Spam 50(1-0.10)45 30(1-0.30)=21 20(1-0.80)=4 70
100(0.50)= 100(0.30)= 100(0.20)= 100
50 30 20
𝑛 3∩𝑆 16
𝑃 3𝑆 = = = 0.533
𝑛 𝑆 30
70
Probability 71
TREE DIAGRAMS
A Tree Diagram depicts the outcomes of events 𝐴1 , 𝐴2 , … 𝐴𝑘 on a set of initial
branches. Secondary branches represent conditional probabilities for events
𝐵1 , 𝐵2 , … 𝐵𝑗 . Each set of branches must sum to one.
𝑃(𝐵1 |𝑨𝟏 ) 𝑃(𝐴1 ∩ 𝐵1 )
𝑃 𝐴1 + 𝑃 𝐴2 + 𝑃 𝐴3 = 1
𝑃(𝑨𝟏 ) 𝑃(𝐵2 |𝑨𝟏 )
𝑃(𝐴1 ∩ 𝐵2 ) 𝑃 𝐵1 𝐴1 + 𝑃 𝐵2 𝐴1 = 1
𝑃(𝐵1 |𝑨𝟐 ) 𝑃(𝐴2 ∩ 𝐵1 )
𝑃(𝑨𝟐 ) 𝑃 𝐵1 𝐴2 + 𝑃 𝐵2 𝐴2 = 1
𝑃(𝐵2 |𝑨𝟐 )
𝑃(𝐴2 ∩ 𝐵2 )
𝑃(𝑨𝟑 ) 𝑃(𝐵 |𝑨
1 𝟑 ) 𝑃(𝐴3 ∩ 𝐵1 ) 𝑃 𝐵1 𝐴3 + 𝑃 𝐵2 𝐴3 = 1
𝑃(𝐵2 |𝑨𝟑 ) 𝑃 𝐴1 ∩ 𝐵1 + 𝑃 𝐴1 ∩ 𝐵2 + 𝑃 𝐴2 ∩ 𝐵1
𝑃(𝐴3 ∩ 𝐵2 ) + 𝑃 𝐴2 ∩ 𝐵2 + 𝑃 𝐴3 ∩ 𝐵1
General Tree Diagram
+ 𝑃 𝐴3 ∩ 𝐵2 = 1
The general Multiplication Rule allows us to calculate the intersection, the
probability that events A and B both occur.
𝑃 𝐴 ∩ 𝐵 = 𝑃 𝐴 × 𝑃 𝐵𝐴 = 𝑃 𝐵 × 𝑃 𝐴𝐵
72
72
Create a tree diagram. 73
isn’t spam?
𝑆 1 = 0.10
Account 1=0.50
𝑆′ 1 = 1 − 0.10 = 0.90
𝑆 2 = 0.30
Account 2=0.30
𝑆′ 2 = 1 − 0.30 = 0.70
𝑆 3 = 0.80
Account 3=0.20
𝑆′ 3 = 1 − 0.80 = 0.20
74
Given an email is spam what is the chance it came from 75
account 3?
𝑆 1 = 0.10
Account 1=0.50
𝑆′ 1 = 1 − 0.10 = 0.90 𝑃(3 ∩ 𝑆)
𝑃 3𝑆 =
𝑃 3 ∩ 𝑆 + 𝑃 2 ∩ 𝑆 + 𝑃(1 ∩ 𝑆)
0.16 0.16
𝑆 2 = 0.30 𝑃 3𝑆 = =
0.16 + 0.05 + 0.09 0.30
Account 2=0.30
𝑆′ 2 = 1 − 0.30 = 0.70
𝑆 3 = 0.80
Account 3=0.20
𝑆′ 3 = 1 − 0.80 = 0.20
75
COUNTING TECHNIQUES
Probability 77
COUNTING TECHNIQUES
Probability problems typically require that we know the total number of
simple events.
Probability 78
MULTIPLICATION RULE
If a task consists of a sequence of choices in which there are p selections for the
first choice, q selections for the second choice, r selections for the third choice, and
so on, then the task of making these selections can be done in
𝑝 ∙ 𝑞 ∙ 𝑟…∙ 𝑧
different ways
Presentation title 79
EXAMPLE
How many 4-number codes can
you generate?
A)Assuming you can repeat digits.
B) Assuming you cannot repeat
digits.
Presentation title 80
FACTORIAL RULE
It is used to find the total number of ways that n different items
can be rearranged when all of them are selected.
𝑁 = 𝑛!
PERMUTATION
A permutation is an ordered arrangement in which r objects are chosen from
n distinct (different) objects so that r≤n and repetition is not allowed. The
symbol 𝑛 𝑃𝑟 , represents the number of permutations of r objects selected
from n objects
EXAMPLE
At the local library, 15 students enter a short-
story contest. How many ways could the first-
place, second-place, and third-place prizes be
awarded?
Presentation title 84
COMBINATION
A combination is a collection, without regard to order, in which r objects are
chosen from n distinct objects with r≤n and without repetition. The symbol
nCr represents the number of combinations of n distinct objects taken r at a
time.
EXAMPLE
In the Illinois Lottery, an urn contains balls
numbered 1–52. From this urn,
six balls are randomly chosen without
replacement. For a $1 bet, a player chooses two
sets of six numbers. To win, all six numbers must
match those chosen from the urn. The
order in which the balls are picked does not
matter. What is the probability of winning
the lottery?
Presentation title 87
EXAMPLE
Find the number of rearrangements of the letters
in the word “CARRIER”
Presentation title 91