Week 5 Chapter 4 Basic Probability
Week 5 Chapter 4 Basic Probability
I Introduction
IV Probabilities summary
I. INTRODUCTION
Basic probability concepts
⚫ Probability – the chance that an uncertain event
will occur (always between 0 and 1)
3. subjective probability
based on a combination of an individual’s past experience,
personal opinion, and analysis of a particular situation
I. INTRODUCTION
Example of a priori probability
number of days in
X
Probability of Day In January T January
total number of days in
2015
X 31days in
T
January
31 365 days in 2015
I. INTRODUCTION
Example of empirical probability
Black 2 24 26
Red 2 24 26
Total 4 48 52
Sample
Space
⚫ Tree diagrams 2
Sample
Space
Full Deck 24
of 52 Cards
2
24
II. ORGANIZING AND VISUSALIZING EVENTS
⚫ Decision Trees
4 Number
Sample Of
27 Sample
Space
All Days Space
48
In 2015 Outcomes
28
II. ORGANIZING AND VISUALIZING EVENTS
2.2.Visualizing events
⚫ Venn Diagrams
◦ Let A = aces
A ∩ B = ace and red
◦ Let B = red cards (intersection)
B
A U B = ace or red
(union)
II. ORGANIZING AND VISUSALIZING EVENTS
January
Days
Wednesdays
II. ORGANIZING AND VISUSALIZING EVENTS
2.3.Simple probability
⚫ Simple probability refers to the probability of a
simple event.
◦ ex. P(Jan.)
◦ ex. P(Wed.)
P(Wed.) = 52 / 365
Jan Not Total
Wed 4 48 52
Not Web 27 286 313
Total 31 334 365
P(Jan.) = 31 / 365
II. ORGANIZING AND VISUSALIZING EVENTS
2.4.Joint probability
⚫ Joint probability refers to the probability of an
occurrence of two or more events (joint event).
◦ ex. P(Jan. and Wed.)
◦ ex. P(Not Jan. and Not Wed.)
Wed 4 48 52
Not Web 27 286 313 P(Not Jan. and Not
Wed.)
Total 31 334 365 = 286 / 365
Example:
Example:
A = Weekday; B = Weekend;
C = January; D = Spring;
⚫ Computing
P(A) P(A andaBmarginal (or Bsimple)
1) P(A and 2 ) P(A and
Bk probability:
)
🞄 Where B1, B2, …, Bk are k mutually exclusive
and collectively exhaustive events
III. JOINT AND MARGINAL PROBABILITIES
Joint probability
Example
P(Jan.) = 31 / 365
P (Not)= 334/365
III. JOINT AND MARGINAL PROBABILITIES
Marginal and joint probability in a contingency
table
Event
Event B1 B2 Total
Solution:
P(Spanish orGerman)=P(Spanish)+P(German)
−P(Spanish
and German)
=0.4+0.2−0.08=0.52
IV. PROBABILITIES
Computing conditional probabilities
⚫ A conditional probability is the probability of one event,
given that another event has occurred:
The conditional
P(A and B)
P(A | B) P(B) probability of A
given that B has
occurred
The conditional
P(A and B) probability of B
P(B | A) P(A) given that A has
occurred
Of the cars on a used car lot, 70% have air conditioning (AC)
and 40% have a GPS. 20% of the cars have both.
AC:
.3
IV. PROBABILITIES
Using decision trees
(continued)
.2
.4 P(GPS and AC) = 0.2
Given GPS or
no GPS:
P(GPS and AC’) = 0.2
.2
.4
Conditional
All Probabilities
Cars
.5
.6 P(GPS’ and AC) = 0.5
.6
IV. PROBABILITIES
Independence
⚫ Two events are independent if and only if:
P(A | B)
P(A)
⚫ Events A and B are independent when the probability of
one event is not affected by the fact that the other event
has occurred
IV. PROBABILITIES
Multiplication rules
⚫ Multiplication rule for two events A and
B:
P(A | B i )P(Bi )
P(B | A)
i
P(A | B )P(B ) P(A | B )P(B )
P(A | 1B )P(B ) 1 2 2
k k
⚫ where:
Bi = ith event of k mutually exclusive and collectively
exhaustive events
IV. PROBABILITIES
Bayes’
Theorem
Example
⚫A drilling company has estimated a 40% chance of
striking oil for their new well.
⚫A detailed test has been scheduled for more
information. Historically, 60% of successful wells
have had detailed tests, and 20% of unsuccessful
wells have had detailed tests.
⚫ Given that this well has been scheduled for a
detailed test, what is the probability
that the well will be successful?
IV. PROBABILITIES
Bayes’ Theorem
⚫ Let S = successful well
U = unsuccessful well
⚫ P(S) = 0.4 , P(U) = 0.6 (prior probabilities)
⚫ Define the detailed test event as D
⚫ Conditional probabilities:
P(D|S) = 0.6 P(D|U) = 0.2
⚫ Goal is to find P(S|D)
IV. PROBABILITIES
Bayes’ Theorem
Apply Bayes’ Theorem:
P(D | S)P(S)
P(S |D)
P(D | S)P(S) P(D |
U)P(U)
(0.6)(0.4)
(0.6)(0.4)
0.24 (0.2)
(0.6)
0.24 0.667
0.12
So the revised probability of success, given that this well
has been scheduled for a detailed test, is 0.667
IV. PROBABILITIES
Sum = 0.36
IV. PROBABILITIES
Counting rules are often useful in computing
probabilities
⚫ Inmany cases, there are a large number of
possible outcomes.
◦ Example
🞄 If you roll a fair die 3 times then there are 63 = 216
possible outcomes
IV. PROBABILITIES
Counting rules
⚫ Counting rule 2:
◦ If there are k1 events on the first trial, k2 events on
the second trial, … and kn events on the nth
trial, the number of possible outcomes is
…
◦ Example: (k1)(k2) (kn)
🞄 You want to go to a park, eat at a restaurant, and see a
movie. There are 3 parks, 4 restaurants, and 6 movie
choices. How many different possible combinations are
there?
🞄 Answer: (3)(4)(6) = 72 different possibilities
IV. PROBABILITIES
Counting rules
⚫ Counting rule 3:
◦ The number of ways that n items can be arranged in
order is …
n! = (n)(n – 1) (1)
◦ Example:
🞄 You have five books to put on a bookshelf.
How many different ways can these books be
placed on the shelf?
n!
n Px
(n X)!
◦ Example:
🞄 You have five books and are going to put three on a
bookshelf. How many different ways can the books be
ordered on the bookshelf?
🞄 Answer:
n! 5!
n Px
120
(n X)! (5 3)! 2 60 different
possibilities
IV. PROBABILITIES
Counting rules
⚫ CountingRule 5:
◦ Combinations: The number of ways of selecting
X objects from n objects, irrespective of order,
is
n!
n Cx
X!(n X)!
◦ Example:
🞄 You have five books and are going to select
three are to read. How many different
combinations are there, ignoring the order in
which they are selected?
🞄 Answer: n!
nC 120 10 different
X!(n5! X)! 3!(5 3)! (6) possibilities
x
(2)