Download Chap. 3: Probability

Document related concepts
Transcript
© 2011 Pearson Education, Inc
Statistics for Business and
Economics
Chapter 3
Probability
© 2011 Pearson Education, Inc
Contents
1.
2.
3.
4.
5.
6.
7.
8.
Events, Sample Spaces, and Probability
Unions and Intersections
Complementary Events
The Additive Rule and Mutually Exclusive
Events
Conditional Probability
The Multiplicative Rule and Independent
Events
Random Sampling
Baye’s Rule
© 2011 Pearson Education, Inc
Learning Objectives
1. Develop probability as a measure of
uncertainty
2. Introduce basic rules for finding
probabilities
3. Use probability as a measure of reliability
for an inference
© 2011 Pearson Education, Inc
Thinking Challenge
• What’s the probability
of getting a head on
the toss of a single fair
coin? Use a scale from
0 (no way) to 1 (sure
thing).
• So toss a coin twice.
Do it! Did you get one
head & one tail?
What’s it all mean?
© 2011 Pearson Education, Inc
Many Repetitions!*
Total Heads
Number of Tosses
1.00
0.75
0.50
0.25
0.00
0
25
50
75
Number of Tosses
© 2011 Pearson Education, Inc
100
125
3.1
Events, Sample Spaces,
and Probability
© 2011 Pearson Education, Inc
Experiments & Sample Spaces
1. Experiment
• Process of observation that leads to a single
outcome that cannot be predicted with certainty
2. Sample point
• Most basic outcome of an
experiment
Sample Space
Depends on
Experimenter!
3. Sample space (S)
• Collection of all possible outcomes
© 2011 Pearson Education, Inc
Sample Space Properties
1. Mutually Exclusive
•
Experiment: Observe Gender
2 outcomes can not
occur at the same
time
— Male & Female in
same person
2. Collectively Exhaustive
•
One outcome in
sample space must
occur.
— Male or Female
© 2011 Pearson Education, Inc
© 1984-1994 T/Maker Co.
Visualizing
Sample Space
1.
Listing
S = {Head, Tail}
2.
Venn Diagram
H
T
S
© 2011 Pearson Education, Inc
Sample Space Examples
•
•
•
•
•
•
•
Experiment
Sample Space
Toss a Coin, Note Face
Toss 2 Coins, Note Faces
Select 1 Card, Note Kind
Select 1 Card, Note Color
Play a Football Game
Inspect a Part, Note Quality
Observe Gender
{Head, Tail}
{HH, HT, TH, TT}
{2♥, 2♠, ..., A♦} (52)
{Red, Black}
{Win, Lose, Tie}
{Defective, Good}
{Male, Female}
© 2011 Pearson Education, Inc
Events
1. Specific collection of sample points
2. Simple Event
• Contains only one sample point
3. Compound Event
• Contains two or more sample points
© 2011 Pearson Education, Inc
Venn Diagram
Experiment: Toss 2 Coins. Note Faces.
Sample Space
S = {HH, HT, TH, TT}
TH
Outcome
HH
Compound
Event: At
least one
Tail
HT
TT
S
© 2011 Pearson Education, Inc
Event Examples
Experiment: Toss 2 Coins. Note Faces.
Sample Space: HH, HT, TH, TT
•
•
•
•
Event
1 Head & 1 Tail
Head on 1st Coin
At Least 1 Head
Heads on Both
Outcomes in Event
HT, TH
HH, HT
HH, HT, TH
HH
© 2011 Pearson Education, Inc
Probabilities
© 2011 Pearson Education, Inc
What is Probability?
1. Numerical measure of the
likelihood that event will
cccur
• P(Event)
• P(A)
• Prob(A)
1
Certain
.5
2. Lies between 0 & 1
3. Sum of sample points is 1
0
© 2011 Pearson Education, Inc
Impossible
Probability Rules
for Sample Points
Let pi represent the probability of sample point i.
1. All sample point probabilities must lie between 0
and 1 (i.e., 0 ≤ pi ≤ 1).
2. The probabilities of all sample points within a
sample space must sum to 1 (i.e.,  pi = 1).
© 2011 Pearson Education, Inc
Equally Likely Probability
P(Event) = X / T
• X = Number of outcomes in the
event
• T = Total number of sample points
in Sample Space
• Each of T sample points is equally
likely
— P(sample point) = 1/T
© 2011 Pearson Education, Inc
© 1984-1994 T/Maker Co.
Steps for Calculating Probability
1. Define the experiment; describe the process used to
make an observation and the type of observation
that will be recorded
2. List the sample points
3. Assign probabilities to the sample points
4. Determine the collection of sample points contained
in the event of interest
5. Sum the sample points probabilities to get the event
probability
© 2011 Pearson Education, Inc
Combinations Rule
A sample of n elements is to be drawn from a set of N
elements. The, the number of different samples possible
 N
is denoted by   and is equal to
n 
 N
N!
 n   n!N  n !
where the factorial symbol (!) means that
n!  n n  1n  2 L 32 1
For example, 5!  5  4  3 2 1
0! is defined to be 1.
© 2011 Pearson Education, Inc
3.2
Unions and Intersections
© 2011 Pearson Education, Inc
Compound Events
Compound events:
Composition of two or more other events.
Can be formed in two different ways.
© 2011 Pearson Education, Inc
Unions & Intersections
1. Union
•
•
•
Outcomes in either events A or B or both
‘OR’ statement
Denoted by  symbol (i.e., A  B)
2. Intersection
•
•
•
Outcomes in both events A and B
‘AND’ statement
Denoted by  symbol (i.e., A  B)
© 2011 Pearson Education, Inc
Event Union:
Venn Diagram
Experiment: Draw 1 Card. Note Kind, Color &
Suit.
Sample
Space:
2, 2, 2,
..., A
Ace
Black
S
Event Ace:
A, A, A, A
Event Ace  Black:
A, ..., A, 2, ..., K
© 2011 Pearson Education, Inc
Event
Black:
2,
2, ...,
A
Event Union:
Two–Way Table
Experiment: Draw 1 Card. Note Kind, Color &
Suit.
Color
Simple
Sample Space
Type
(S):
Ace
2, 2, 2,
..., A
Non-Ace
Total
Event
Ace  Black:
A,..., A, 2, ..., K
Total
Ace & Ace & Ace
Red
Black
Non & Non & NonRed
Black Ace
Red
Black
S
Red
Black
Simple Event Black:
2, ..., A
© 2011 Pearson Education, Inc
Event
Ace:
A,
A,
A,
A
Event Intersection:
Venn Diagram
Experiment: Draw 1 Card. Note Kind, Color &
Suit.
Sample
Space:
2, 2, 2,
..., A
Ace
Black
S
Event Ace:
A, A, A, A
Event Ace  Black:
A, A
© 2011 Pearson Education, Inc
Event
Black:
2,...,A
Event Intersection:
Two–Way Table
Experiment: Draw 1 Card. Note Kind, Color &
Suit.
Color
Sample Space
Type
(S):
Ace
2, 2, 2,
..., A
Non-Ace
Event
Ace  Black:
A, A
Total
Total
Ace & Ace & Ace
Red
Black
Non & Non & NonRed
Black Ace
Red
Black
S
Red
Black
Simple
Event
Ace:
A, A,
A, A
Simple Event Black: 2, ..., A
© 2011 Pearson Education, Inc
Compound Event Probability
1. Numerical measure of likelihood that
compound event will occur
2. Can often use two–way table
• Two variables only
© 2011 Pearson Education, Inc
Event Probability Using
Two–Way Table
Event
Event
B1
B2
Total
A1
P(A 1  B1) P(A 1  B2) P(A 1)
A2
P(A 2  B1) P(A 2  B2) P(A 2)
Total
Joint Probability
P(B 1)
P(B 2)
1
Marginal (Simple) Probability
© 2011 Pearson Education, Inc
Two–Way Table Example
Experiment: Draw 1 Card. Note Kind & Color.
Color
Type
Red
Black
Total
Ace
2/52
2/52
4/52
Non-Ace
24/52
24/52
48/52
Total
26/52
26/52
52/52
P(Red)
P(Ace  Red)
© 2011 Pearson Education, Inc
P(Ace)
Thinking Challenge
What’s the Probability?
1. P(A) =
2. P(D) =
Event
C
D
4
2
3. P(C  B) =
Event
A
4. P(A  D) =
B
1
3
4
5. P(B  D) =
Total
5
5
10
© 2011 Pearson Education, Inc
Total
6
Solution*
The Probabilities Are:
1. P(A) = 6/10
2. P(D) = 5/10
Event
C
D
4
2
3. P(C  B) = 1/10
Event
A
4. P(A  D) = 9/10
B
1
3
4
5. P(B  D) = 3/10 Total
5
5
10
© 2011 Pearson Education, Inc
Total
6
3.3
Complementary Events
© 2011 Pearson Education, Inc
Complementary Events
Complement of Event A
• The event that A does not occur
• All events not in A
• Denote complement of A by AC
AC
A
© 2011 Pearson Education, Inc
S
Rule of Complements
The sum of the probabilities of complementary events
equals 1:
P(A) + P(AC) = 1
AC
A
© 2011 Pearson Education, Inc
S
Complement of Event
Example
Experiment: Draw 1 Card. Note Color.
Black
Sample
Space:
2, 2, 2,
..., A
Event Black:
2, 2, ..., A
S
Complement of Event Black,
BlackC: 2, 2, ..., A, A
© 2011 Pearson Education, Inc
3.4
The Additive Rule and
Mutually Exclusive Events
© 2011 Pearson Education, Inc
Mutually Exclusive Events
Mutually Exclusive Events
• Events do not occur
simultaneously
• A  B does not contain
any sample points

© 2011 Pearson Education, Inc
Mutually Exclusive
Events Example
Experiment: Draw 1 Card. Note Kind & Suit.
Sample
Space:
2, 2,
2, ..., A


Event Spade:
2, 3, 4, ..., A
S
Outcomes
in Event
Heart:
2, 3, 4
, ..., A
Events  and are Mutually Exclusive
© 2011 Pearson Education, Inc
Additive Rule
1. Used to get compound probabilities for
union of events
2. P(A OR B) = P(A  B)
= P(A) + P(B) – P(A  B)
3. For mutually exclusive events:
P(A OR B) = P(A  B) = P(A) + P(B)
© 2011 Pearson Education, Inc
Additive Rule Example
Experiment: Draw 1 Card. Note Kind & Color.
Color
Type
Ace
Red
Black
2
2
Total
4
Non-Ace
24
24
48
Total
26
26
52
P(Ace  Black) = P(Ace) + P(Black) – P(Ace  Black)
4
26
2 28
=
+
–
=
52
52 52 52
© 2011 Pearson Education, Inc
Thinking Challenge
Using the additive rule, what is the probability?
1. P(A  D) =
2. P(B  C) =
Event
A
Event
C
D
4
2
Total
6
B
1
3
4
Total
5
5
10
© 2011 Pearson Education, Inc
Solution*
Using the additive rule, the probabilities are:
1. P(A  D) = P(A) + P(D) – P(A  D)
6
5
2
9
=
+
–
=
10 10 10 10
2. P(B  C) = P(B) + P(C) – P(B  C)
4
5
1
8
=
+
–
=
10 10 10 10
© 2011 Pearson Education, Inc
3.5
Conditional Probability
© 2011 Pearson Education, Inc
Conditional Probability
1. Event probability given that another event
occurred
2. Revise original sample space to account for
new information
• Eliminates certain outcomes
3. P(A | B) = P(A and B) = P(A  B
P(B)
P(B)
© 2011 Pearson Education, Inc
Conditional Probability Using
Venn Diagram
Ace
Black
S
Event (Ace  Black)
© 2011 Pearson Education, Inc
Black ‘Happens’:
Eliminates All
Other Outcomes
Black
(S)
Conditional Probability Using
Two–Way Table
Experiment: Draw 1 Card. Note Kind & Color.
Color
Type
Red
Black
Ace
2
2
Total
4
Non-Ace
24
24
48
Total
26
26
52
Revised
Sample
Space
P(Ace  Black) 2 / 52
2
P(Ace | Black) =


P(Black)
26 / 52 26
© 2011 Pearson Education, Inc
Thinking Challenge
Using the table then the formula, what’s the
probability?
1. P(A|D) =
2. P(C|B) =
Event
A
Event
C
D
4
2
Total
6
B
1
3
4
Total
5
5
10
© 2011 Pearson Education, Inc
Solution*
Using the formula, the probabilities are:
P A  B  2 5 2
P A D  


5
P D 
5
10
P C  B  110 1
P C B  


4
P B 
4
10
© 2011 Pearson Education, Inc
3.6
The Multiplicative Rule
and Independent Events
© 2011 Pearson Education, Inc
Multiplicative Rule
1. Used to get compound probabilities for
intersection of events
2. P(A and B) = P(A  B)
= P(A)  P(B|A)
= P(B)  P(A|B)
3. For Independent Events:
P(A and B) = P(A  B) = P(A)  P(B)
© 2011 Pearson Education, Inc
Multiplicative Rule Example
Experiment: Draw 1 Card. Note Kind & Color.
Color
Type
Ace
Red
Black
2
2
Total
4
Non-Ace
24
24
48
Total
26
26
52
P(Ace  Black) = P(Ace)∙P(Black | Ace)
 4  2  2
    
 52  4  52
© 2011 Pearson Education, Inc
Statistical Independence
1. Event occurrence does not affect probability of
another event
• Toss 1 coin twice
2. Causality not implied
3. Tests for independence
• P(A | B) = P(A)
• P(B | A) = P(B)
• P(A  B) = P(A)  P(B)
© 2011 Pearson Education, Inc
Thinking Challenge
Using the multiplicative rule, what’s the
probability?
1. P(C  B) =
Event
C
D
4
2
2. P(B  D) =
Event
A
3. P(A  B) =
B
1
3
4
Total
5
5
10
© 2011 Pearson Education, Inc
Total
6
Solution*
Using the multiplicative rule, the probabilities
are:
5 1 1
P C  B   P C  P B C    
10 5 10
4 3 6
P B  D   P B  P D B    
10 5 25
P A  B   P A  P B A   0
© 2011 Pearson Education, Inc
Tree Diagram
Experiment: Select 2 pens from 20 pens: 14
blue & 6 red. Don’t replace.
Dependent!
5/19
6/20
P(R  R)=(6/20)(5/19) =3/38
B
R
P(R  B)=(6/20)(14/19) =21/95
B
P(B  B)=(14/20)(13/19) =91/190
R
14/19
14/20
R
6/19
P(B  R)=(14/20)(6/19) =21/95
B
13/19
© 2011 Pearson Education, Inc
3.7
Random Sampling
© 2011 Pearson Education, Inc
Importance of Selection
How a sample is selected from a population is
of vital importance in statistical inference
because the probability of an observed sample
will be used to infer the characteristics of the
sampled population.
© 2011 Pearson Education, Inc
Random Sample
If n elements are selected from a population in
such a way that every set of n elements in the
population has an equal probability of being
selected, the n elements are said to be a
random sample.
© 2011 Pearson Education, Inc
Random Number Generators
Most researchers rely on random number
generators to automatically generate the
random sample.
Random number generators are available in
table form, and they are built into most
statistical software packages.
© 2011 Pearson Education, Inc
3.8
Bayes’s Rule
© 2011 Pearson Education, Inc
Bayes’s Rule
Given k mutually exclusive and exhaustive
events B1, B1, . . . Bk , such that
P(B1) + P(B2) + … + P(Bk) = 1,
and an observed event A, then
P(Bi  A)
P(Bi | A) 
P( A)
P(Bi )P( A | Bi )

P(B1 )P( A | B1 )  P(B2 )P( A | B2 )  ...  P(Bk )P( A | Bk )
© 2011 Pearson Education, Inc
Bayes’s Rule Example
A company manufactures MP3 players at two
factories. Factory I produces 60% of the MP3
players and Factory II produces 40%. Two
percent of the MP3 players produced at Factory
I are defective, while 1% of Factory II’s are
defective. An MP3 player is selected at random
and found to be defective. What is the
probability it came from Factory I?
© 2011 Pearson Education, Inc
Bayes’s Rule Example
0 .6
0 .4
Factory
I
Factory
II
0.02
Defective
0.98
Good
0.01
Defective
0.99
Good
P( I | D) 
P(I )P( D | I )
0.6  0.02

 0.75
P(I )P( D | I )  P(II )P(D | II ) 0.6  0.02  0.4  0.01
© 2011 Pearson Education, Inc
Key Ideas
Probability Rules for k Sample Points,
S1, S2, S3, . . . , Sk
1. 0 ≤ P(Si) ≤ 1
2.
 P S   1
i
© 2011 Pearson Education, Inc
Key Ideas
Random Sample
All possible such samples have equal
probability of being selected.
© 2011 Pearson Education, Inc
Key Ideas
Combinations Rule
Counting number of samples of n elements
selected from N elements
 N
N N  1N  2 L N  n  1
N!
 n   n!N  n ! 
n n  1n  2 L 2 1
© 2011 Pearson Education, Inc
Key Ideas
Bayes’s Rule
P(Si | A) 
P(Si )P( A | Si )
P(S1 )P( A | S1 )  P(S2 )P( A | S2 )  ...  P(Sk )P( A | Sk )
© 2011 Pearson Education, Inc