chapter 6 probability. assigning probabilities to events random experiment –a random experiment is...

41
Chapter 6 Probabil ity

Upload: berniece-bridges

Post on 25-Dec-2015

249 views

Category:

Documents


6 download

TRANSCRIPT

Page 1: Chapter 6 Probability. Assigning probabilities to Events Random experiment –a random experiment is a process or course of action, whose outcome is uncertain

Chapter 6 ProbabilityChapter 6 Probability

Page 2: Chapter 6 Probability. Assigning probabilities to Events Random experiment –a random experiment is a process or course of action, whose outcome is uncertain

Assigning probabilities to Events

• Random experiment– a random experiment is a process or course of action,

whose outcome is uncertain.

• Examples Experiment Outcomes

• Flip a coin Heads and Tails

• Record a statistics test marks Numbers between 0 and

100

• Measure the time to assemble numbers from zero to computer infinite

Page 3: Chapter 6 Probability. Assigning probabilities to Events Random experiment –a random experiment is a process or course of action, whose outcome is uncertain

Probabilities…

• List the outcomes of a random experiment…• This list must be exhaustive, i.e. ALL possible

outcomes included.

Die roll {1,2,3,4,5} Die roll {1,2,3,4,5,6}• The list must be mutually exclusive, i.e. no

two outcomes can occur at the same time:

Die roll {odd number or even number}

Die roll{ number less than 4 or even number}

Page 4: Chapter 6 Probability. Assigning probabilities to Events Random experiment –a random experiment is a process or course of action, whose outcome is uncertain

Assigning probabilities to Events

• Performing the same random experiment repeatedly, may result in different outcomes, therefore, the best we can do is consider the probability of occurrence of a certain outcome.

• To determine the probabilities we need to define and list the possible outcomes first.

Page 5: Chapter 6 Probability. Assigning probabilities to Events Random experiment –a random experiment is a process or course of action, whose outcome is uncertain

• Determining the outcomes.– Build an exhaustive list of all possible

outcomes.– Make sure the listed outcomes are mutually

exclusive.

• A list of outcomes that meets the two conditions above is called a sample space.

Sample Space

Page 6: Chapter 6 Probability. Assigning probabilities to Events Random experiment –a random experiment is a process or course of action, whose outcome is uncertain

Sample Space: S = {O1, O2,…,Ok}

Sample Spacea sample space of a random experimentis a list of all possible outcomes of the experiment. The outcomes must be mutually exclusive and exhaustive.

Simple EventsThe individual outcomes are called simple events. Simple events cannot be further decomposed into constituent outcomes.

EventAn event is any collectionof one or more simple events

Our objective is to determine P(A), the probability that event A will occur.

Our objective is to determine P(A), the probability that event A will occur.

O1 O2

Page 7: Chapter 6 Probability. Assigning probabilities to Events Random experiment –a random experiment is a process or course of action, whose outcome is uncertain

– Given a sample space S={O1,O2,…,Ok}, the following characteristics for the probability P(Oi) of the simple event Oi must hold:

– Probability of an event: The probability P(A) of event A is the sum of the probabilities assigned to the simple events contained in A.

k

ii

i

OP

ieachforOP

1

1.2

10.1

k

ii

i

OP

ieachforOP

1

1.2

10.1

Assigning Probabilities

Page 8: Chapter 6 Probability. Assigning probabilities to Events Random experiment –a random experiment is a process or course of action, whose outcome is uncertain

Approaches to Assigning Probabilities…

•There are three ways to assign a probability, P(Oi), to an outcome, Oi, namely:•Classical approach: make certain assumptions (such as equally likely, independence) about situation.•Relative frequency: assigning probabilities based on experimentation or historical data.•Subjective approach: Assigning probabilities based on the assignor’s judgment.

Page 9: Chapter 6 Probability. Assigning probabilities to Events Random experiment –a random experiment is a process or course of action, whose outcome is uncertain

Example 1(Textbook 6.3)

• A quiz contains multiple-choice questions with five possible answers, only one of which is correct. A student plans to guess the answers because he knows absolutely nothing about the subject.

a. Produce the sample space for each question.b. Assign probabilities to the simple events in the

sample space you produced.c. Which approach did you use to answer part bd. Interpret the probabilities you assigned in part b

Page 10: Chapter 6 Probability. Assigning probabilities to Events Random experiment –a random experiment is a process or course of action, whose outcome is uncertain

Solution

• a {a is correct, b is correct, c is correct, d is correct, e is correct}

• b P(a is correct) = P(b is correct) = P(c is correct) = P(d is correct) = P(e is correct) = .2

• c Classical approach

• d In the long run all answers are equally likely to be correct.

Page 11: Chapter 6 Probability. Assigning probabilities to Events Random experiment –a random experiment is a process or course of action, whose outcome is uncertain

Joint, Marginal, and Conditional Probability

• We study methods to determine probabilities of events that result from combining other events in various ways.

• There are several types of combinations and relationships between events:– Intersection of events– Union of events– Dependent and independent events– Complement event

Page 12: Chapter 6 Probability. Assigning probabilities to Events Random experiment –a random experiment is a process or course of action, whose outcome is uncertain

Intersection• The intersection of event A and B is the event that

occurs when both A and B occur.

• The intersection of events A and B is denoted by (A and B).

• The joint probability of A and B is the probability of the intersection of A and B, which is denoted by P(A and B)

Page 13: Chapter 6 Probability. Assigning probabilities to Events Random experiment –a random experiment is a process or course of action, whose outcome is uncertain

• Additional Example – 1 – The number of spots turning up when a six-side die

is tossed is observed. Consider the following events.– A: The number observed is at most 2.– B: The number observed is an even number.

– Determine the probability of the intersection event A and B.

5

31

2

46

B

A A and B

46

1

222 P(A and B) = P(2) = 1/6

Intersection

Page 14: Chapter 6 Probability. Assigning probabilities to Events Random experiment –a random experiment is a process or course of action, whose outcome is uncertain

Marginal Probability

• These probabilities are computed by adding across rows and down columns

Mutual fund outperforms the market (B1)

Mutual fund doesn’t outperform the market (B2)

Marginal Prob.

P(Ai)

Top 20 MBA program (A1)

Not top 20 MBA program (A2)

Marginal Probability P(Bj)

P(A1 and B1)+ P(A1 and B2) = P(A1)

P(A2 and B1)+ P(A2 and B2) = P(A2)

Page 15: Chapter 6 Probability. Assigning probabilities to Events Random experiment –a random experiment is a process or course of action, whose outcome is uncertain

Marginal Probability

• These probabilities are computed by adding across rows and down columns

Mutual fund outperforms the market (B1)

Mutual fund doesn’t outperform the market (B2)

Marginal Prob.

P(Ai)

Top 20 MBA program (A1) .40Not top 20 MBA program (A2)

.60

Marginal Probability P(Bj)

P(A1 and B1)+

P(A2 and B1 = P(B1)

P(A1 and B2)+

P(A2 and B2 = P(B2)

Page 16: Chapter 6 Probability. Assigning probabilities to Events Random experiment –a random experiment is a process or course of action, whose outcome is uncertain

• Example 6.2 (Example 6.1 – continued)– Find the conditional probability that a randomly

selected fund is managed by a “Top 20 MBA Program graduate”, given that it did not outperform the market.

• SolutionP(A1|B2) = P(A1 and B2) = .29 = .3949

P(B2) .83

Conditional Probability

Page 17: Chapter 6 Probability. Assigning probabilities to Events Random experiment –a random experiment is a process or course of action, whose outcome is uncertain

Independence

• Independent events– Two events A and B are said to be

independent if

P(A|B) = P(A)or

P(B|A) = P(B)– That is, the probability of one event is not

affected by the occurrence of the other event.

Page 18: Chapter 6 Probability. Assigning probabilities to Events Random experiment –a random experiment is a process or course of action, whose outcome is uncertain

Union

• The union event of A and B is the event that occurs when either A or B or both occur.

• It is denoted “A or B”.

Page 19: Chapter 6 Probability. Assigning probabilities to Events Random experiment –a random experiment is a process or course of action, whose outcome is uncertain

Example 2

• Suppose we have the following joint probabilities

• Compute the marginal probabilities

A1 A2 A3

B1 0.2 0.15 0.1

B2 0.25 0.25 0.05

Page 20: Chapter 6 Probability. Assigning probabilities to Events Random experiment –a random experiment is a process or course of action, whose outcome is uncertain

Solution

Page 21: Chapter 6 Probability. Assigning probabilities to Events Random experiment –a random experiment is a process or course of action, whose outcome is uncertain

Example 3• The following tables lists the joint probabilities associated with smoking and

lung disease among 60 to 65 year-old-men.

• One 60 to 65 year old man is selected at random. What is the probability of the following events

a. He is a smokerb. He does not have lung diseasec. He has lung disease given that he is a smokerd. He has lung disease given that he does not smoke

He is a smoker He is a nonsmoker

He has lung disease

0.1 0.03

He does not have lung disease

0.21 0.66

Page 22: Chapter 6 Probability. Assigning probabilities to Events Random experiment –a random experiment is a process or course of action, whose outcome is uncertain

Solution

Page 23: Chapter 6 Probability. Assigning probabilities to Events Random experiment –a random experiment is a process or course of action, whose outcome is uncertain

Probability Rules and Trees

• We present more methods to determine the probability of the intersection and the union of two events.

• Three rules assist us in determining the probability of complex events from the probability of simpler events.

Page 24: Chapter 6 Probability. Assigning probabilities to Events Random experiment –a random experiment is a process or course of action, whose outcome is uncertain

Complement Rule

• The complement of event A (denoted by AC) is the event that occurs when event A does not occur.

• The probability of the complement event is calculated by

P(AC) = 1 - P(A)P(AC) = 1 - P(A)A and AC consist of all the simple events in the sample space. Therefore,P(A) + P(AC) = 1

Page 25: Chapter 6 Probability. Assigning probabilities to Events Random experiment –a random experiment is a process or course of action, whose outcome is uncertain

• For any two events A and B

• When A and B are independent

P(A and B) = P(A)P(B|A)= P(B)P(A|B)

P(A and B) = P(A)P(B|A)= P(B)P(A|B)

P(A and B) = P(A)P(B)P(A and B) = P(A)P(B)

Multiplication Rule

Page 26: Chapter 6 Probability. Assigning probabilities to Events Random experiment –a random experiment is a process or course of action, whose outcome is uncertain

• This is a useful device to calculate probabilities when using the probability rules.

Probability Trees

Page 27: Chapter 6 Probability. Assigning probabilities to Events Random experiment –a random experiment is a process or course of action, whose outcome is uncertain

Example 4 (Textbook 6.52)

• Approximately 10% of people are left-handed. If two people are selected at random, what is the probability of the following events?

a. Both are right-handedb. Both are left-handedc. One is right-handed and the other is left-

handedd. At least one is right-handed

Page 28: Chapter 6 Probability. Assigning probabilities to Events Random experiment –a random experiment is a process or course of action, whose outcome is uncertain

Solution

Page 29: Chapter 6 Probability. Assigning probabilities to Events Random experiment –a random experiment is a process or course of action, whose outcome is uncertain

For any two events A and B

P(A or B) = P(A) + P(B) - P(A and B)P(A or B) = P(A) + P(B) - P(A and B)

A

B

P(A) =6/13

P(B) =5/13

P(A and B) =3/13

A or B

+_

P(A or B) = 8/13

Addition Rule

Page 30: Chapter 6 Probability. Assigning probabilities to Events Random experiment –a random experiment is a process or course of action, whose outcome is uncertain

B

When A and B are mutually exclusive,

P(A or B) = P(A) + P(B)P(A or B) = P(A) + P(B)

Addition Rule

A B

P(A and B) = 0

Page 31: Chapter 6 Probability. Assigning probabilities to Events Random experiment –a random experiment is a process or course of action, whose outcome is uncertain

決勝二十一點數學問題• 當你上益智節目,主持人有三個門讓你選,其中

一個門打開有百萬名車帶回家,另外兩個門是兩串蕉說掰掰,假如你隨便選了一個門是 A 門好了,這時候主持人為了節目效果,打開了 C 門,後面空無一物,現在只剩下 A , B 兩個門了,主持人再問你要不要換選擇,這時候到底該選哪一個門?

• 要記住,主持人一開始就知道哪個門有百萬名車,為了節目效果,不論你一開始選中或是沒中,他都一定會讓你有再選一次的機會!這就是整個機率關鍵的 Scenario !

Page 32: Chapter 6 Probability. Assigning probabilities to Events Random experiment –a random experiment is a process or course of action, whose outcome is uncertain

【凡人都能懂的版】 Solution

• 選了 A 之後, A 的機率是三分之一,把「 B 和 C 」視為一體,加起來的機率是三分之二,當主持人說出 C 不是之後,他可以完全肯定如果獎在「 B 和 C 」這一組,就一定是 B ,所以這三分之二的機率就完全算在 B 頭上了。就這樣而已。

Page 33: Chapter 6 Probability. Assigning probabilities to Events Random experiment –a random experiment is a process or course of action, whose outcome is uncertain

【有簡單機率背景的人的版】 Solution

• 條件機率問題• 用數學來算,就要分為你 ( 妳 ) 選對了門,主持人

拿掉 C 的機率和你 ( 妳 ) 選錯了門時,主持人拿掉 C 的機率,這兩種情況來算,最後的計算結果,還是會跟上面一樣。( B 是對的機率 = 「 A 是對的機率」 X 「 B 才是對的機率」 + 「 A 是錯的機率」 X 「 B 才是對的機率」 = 「 1/3 」 X 「 0 」+ 「 2/3 」 X 「 1 」 = 「 2/3 」)

Page 34: Chapter 6 Probability. Assigning probabilities to Events Random experiment –a random experiment is a process or course of action, whose outcome is uncertain

Bayes’ Law

• Conditional probability is used to find the probability of an event given that one of its possible causes has occurred.

• We use Bayes’ law to find the probability of the possible cause given that an event has occurred.

Page 35: Chapter 6 Probability. Assigning probabilities to Events Random experiment –a random experiment is a process or course of action, whose outcome is uncertain

• Example – Medical tests can produce false-positive or false-

negative results.– A particular test is found to perform as follows:

• Correctly diagnose “Positive” 94% of the time.• Correctly diagnose “Negative” 98% of the time.

– It is known that 4% of men in the general population suffer from the illness.

– What is the probability that a man is suffering from the illness, if the test result were positive?

Bayes’ Law

Page 36: Chapter 6 Probability. Assigning probabilities to Events Random experiment –a random experiment is a process or course of action, whose outcome is uncertain

• Solution– Define the following events

• D = Has a disease • DC = Does not have the disease• PT = Positive test results• NT = Negative test results

– Build a probability tree

Bayes’ Law

Page 37: Chapter 6 Probability. Assigning probabilities to Events Random experiment –a random experiment is a process or course of action, whose outcome is uncertain

• Solution – Continued– The probabilities provided are:

• P(D) = .04 P(DC) = .96• P(PT|D) = .94 P(NT|D)= .06• P(PT|DC) = .02 P(NT|DC) = .98

– The probability to be determined is)PT|D(P

Bayes’ Law

Page 38: Chapter 6 Probability. Assigning probabilities to Events Random experiment –a random experiment is a process or course of action, whose outcome is uncertain

D D

P(PT|DC ) = .02

P( NT|D C) = .98

P(PT|D) = .94

P( NT|D) = .06

PT|DPT|D

PT|DPTPT|DPTPTPTPTPT

DDDD|

PT

P(D C) = .96

P(D) = .04

PT|D PT|DPT|D

P(D and PT)=.0376

P(DC and PT)=.0192

)PT|D(P

P(PT) =.0568

+ )PT(P)PTandD(P

6620.0568.0376.

Bayes’ Law

Page 39: Chapter 6 Probability. Assigning probabilities to Events Random experiment –a random experiment is a process or course of action, whose outcome is uncertain

P(PT|DC ) = .02

P( NT|D C) = .98

P(PT|D) = .94

P( NT|D) = .06

P(D C) = .96

P(D) = .04

)PT|D(P 6620.0568.0376.

Bayes’ Law

Prior probabilities

Likelihoodprobabilities

Posterior probabilities

Page 40: Chapter 6 Probability. Assigning probabilities to Events Random experiment –a random experiment is a process or course of action, whose outcome is uncertain

Bayes’ Theorem

• To find the posterior probability that event Ai will occur given that event B has occurred we apply Bayes’ theorem.

• Bayes’ theorem is applicable when the events for which we want to compute posterior probabilities are mutually exclusive and their union is the entire sample space.

P A BA B A

A B A A B A A B Aii i

n n

( | )( ) ( | )

( ) ( | ) ( ) ( | ) ... ( ) ( | )

P P

P P P P P P1 1 2 2

P A BA B A

A B A A B A A B Aii i

n n

( | )( ) ( | )

( ) ( | ) ( ) ( | ) ... ( ) ( | )

P P

P P P P P P1 1 2 2

Page 41: Chapter 6 Probability. Assigning probabilities to Events Random experiment –a random experiment is a process or course of action, whose outcome is uncertain

Bayesian Terminology…

• The probabilities P(A) and P(AC) are called prior probabilities because they are determined prior to the decision about taking the preparatory course.

• The conditional probability P(A | B) is called a posterior probability (or revised probability), because the prior probability is revised after the decision about taking the preparatory course.