Probability and Sampling: Part I. What are the odds? What are the odds of finding a newspaper at the...

Post on 17-Dec-2015

218 views 4 download

Transcript of Probability and Sampling: Part I. What are the odds? What are the odds of finding a newspaper at the...

Probability and Sampling: Part I

What are the odds?

What are the odds of finding a newspaper at the news stand?New York timesVillage VoiceJerusalem Post

From a deck of cards:What are the odds of getting the king of spades?What are the odds of getting a king?What are the odds of getting a diamond suit?

From Reason

From Experience

1/52 or 0.01924/52 or 0.0769

13/52 or 0.2500

Sampling and Probability

What is the probability ofpulling out a red marble ?

P( R) = Total number of Red marbles Total number of marbles

What about probabilities for MULTIPLE events?

P( R) = 7/12 or .5833

Bag of 7 red and 4 blue, 1 white marbles.

Two Rules for Probabilities of Multiple Events

Addition rule: “or”Probability of a red or a blue marble?

Multiplication rule: “and”Probability of a red and a blue marble?

- Mutually exclusive events- Non-mutually exclusive events

- With replacement- Without replacement

Addition Rule: (Part I)What is the probability of getting a white or a red marble?

P(W or R) = P(W) + P(R)

P(W or R) = 1/12 + 7/12

P(W or R) = 8/12 = .6667

Bag of 7 red and 4 blue, 1 white marbles.

Addition Rule: (Part II)What is the probability of getting a red or a glossy marble?

Mutually exclusive events do not require subtraction

Glossy marbles

P(R or G) = P(R) + P(G)

P(R or G) = 7/12 + 2/12 – 1/12

P(R or G) = 8/12 = .6667

– P(R & G)

Addition Rule: (Part I)What is the probability of getting a white or a red marble?

P(W or R) = P(W) + P(R)

P(W or R) = 1/12 + 7/12

P(W or R) = 8/12 = .6667

Can a marble be both white and red at the same time? No, so these are mutually exclusive events, which do NOT require subtraction.

Bag of 7 red and 4 blue, 1 white marbles.

Multiplication Rule: (Part I)What is the probability of getting a white and then a red marble?

If you do put the first marble back.

P(W and then R) = P(W) * P(R)

P(W and then R) = 1/12 * 7/12

P(W and then R) = 7/144 = .0486

If you put the objects back after you’ve taken them out, you have sampled with replacement.

Bag of 7 red and 4 blue, 1 white marbles.

Bag of 7 red and 4 blue, 1 white marbles.

Multiplication Rule: (Part I)What is the probability of getting a white and then a red marble?

If you do NOT put the first marble back.

P(W and then R) = P(W) * P(R|W)

P(W and then R) = 1/12 * 7/11

P(W and then R) = 7/132 = .0530

If you do not put the objects back after you’ve taken them out, you have sampled without replacement.

Multiplication Rule: (Part II)How to handle sequences of events: What is the probability of reaching into a fresh bag and getting the sequence R, W, B, R, R?

P(R) = P(W|R) = P(B|R, W) = P(R|R, W, B) = P(R|R, W, B, R) =

7/121/11

4/106/9

5/8

Without replacement

(7/12)(1/11)(4/10)(6/9)(5/8) = .0088

Sum of Two Fair Dice1 2 3 4 5 6

1 2 3 4 5 6 72 3 4 5 6 7 83 4 5 6 7 8 94 5 6 7 8 9 105 6 7 8 9 10 116 7 8 9 10 11 12

There is only one way to make a “2”two dice in one toss “1” and “1”

There is only one way to make a “12”two dice in one toss “6” and “6”

Sum of Two Fair Dice1 2 3 4 5 6

1 2 3 4 5 6 72 3 4 5 6 7 83 4 5 6 7 8 94 5 6 7 8 9 105 6 7 8 9 10 116 7 8 9 10 11 12

There are 6 ways to make a “7”with two dice in one toss:Die 1 = 6, Die 2 =1Die 1 = 5, Die 2 =2Die 1 = 4, Die 2 =3Die 1 = 1, Die 2 =6Die 1 = 2, Die 2 =5Die 1 = 3, Die 2 =4

The Probability Distribution of Two Six Sided Dice

Pair of Fair Six-Sided Dice

0

1

2

3

4

5

6

2 3 4 5 6 7 8 9 10 11 12

Outcome (sum of two dice)

Fre

quen

cy

Pro

babi

lity

.1667

.0000

.0278

.0556

.0833

.1111

.1389

The Probability Distribution of Two Six Sided Dice

Pair of Fair Six-Sided Dice

0

1

2

3

4

5

6

2 3 4 5 6 7 8 9 10 11 12

Outcome (sum of two dice)

Fre

quen

cy

Pro

babi

lity

.1667

.0000

.0278

.0556

.0833

.1111

.1389

H

TO.5

O.5

A single event that can go one of two ways -- Two mutually exclusive events.

Coin Toss

Expressed as probability: Two possible outcomes with

equal likelihood.

P(H) = ½ = 0.5P(T) = ½ = 0.5

Baseline probability

Multiplication rule for calculating the probability of a sequence of outcomes ...

H

TO.5

O.5

P(HT) = P(H) * P(T) = (0.5)(0.5) = 0.25

P(TH) = P(T) * P(H) = (0.5)(0.5) = 0.25

P(TT) = P(T) * P(T) = (0.5)(0.5) = 0.25

H

TO.5

O.5

H

TO.5

O.5

P(HH) = P(H) * P(H)

Independent events, Sampling with replacement

HH

HT

TH

TT

Outcomes Probability of landing on heads twice in a row

= Probability of landing on heads on the first flip

Probability of landing on heads on the second flip

What about multiple events? (More than one flip of the coin)

P(HH) = 0.25

P(HT) = 0.25

P(TH) = 0.25

P(TT) = 0.25

} P(1 T) = 0.25 + 0.25 = 0.5

P(0 T) = 0.25

P(2 T) = 0.25

# of Tails

HH

HT

TH

TT

Outcomes

Addition rule for calculating the probability of outcomes that are of the same kind:

H

TO.5

O.5

H

TO.5

O.5

H

TO.5

O.5

If we plot the outcomes as a histogram we begin to see a familiar shape.

0 1 2

This works for Sequences of any length

H

TO.5

O.5

H

H

H

HT

T

T

H

H

T

T

T

0 1 2

The Binomial Table A list of ALL the possible outcomes of N events when each event only has two outcomes.

Flip a coin 3 times, what’s the probability of 0 tails?:Flip a coin 2 times, what’s the probability of 2 tails?:Flip a coin 4 times, what’s the probability of 4 tails?:Flip a coin 3 times, what’s the probability of 1 head?:Flip a coin 4 times, what’s the probability of 3 heads?:

.1250

.2500

.0625

.3750.2500

Flip a coin 3 times, what’s the probability of 2 or more tails?:

Flip a coin 2 times, what’s the probability of 1 or less tails?:

Flip a coin 4 times, what’s the probability of 2 or less tails?:

Flip a coin 3 times, what’s the probability of 1 or more heads?:

.5000

.7500

.6875

.8750

The Binomial Table A list of ALL the possible outcomes of N events when each event only has two outcomes.

Ever wonder how likely you are to pass a True/False exam if you JUST GUESSED? Assume there are 20 true/false questions on the exam.

You need to answer 13 or more correctly to get a 65+.

.0739 + .0370 + .0148 + .0046 +.0011 + .0002 + .0000 + .0000 = .1316 or 13.16% chance

P(13) + p(14) + p(15) + p(16) + p(17) + p(18) + p(19) + p(20)

The Binomial Table A list of ALL the possible outcomes of N events when each event only has two outcomes.

What if the baseline probability is not .50?Suppose you are given a coin which you KNOW is weighted: 60% of the time it shows up heads, and 40% of the time it shows up tails.

What is the probability of obtaining 3 tails out of 4 flips of this coin?

What is the probability of obtaining 0 heads out of 4 flips of the coin?

What is the probability of obtaining 0 tails out of 4 flips of this coin? What is the probability of obtaining 3 heads out of 4 flips of this coin?

.1536

.1296.3456.0256

The Binomial Table A list of ALL the possible outcomes of N events when each event only has two outcomes.

What if the baseline probability is not .50?Suppose you are given a coin which you KNOW is weighted: 60% of the time it shows up heads, and 40% of the time it shows up tails.

What is the probability of obtaining 1 or more heads out of 3 flips of the coin?

What is the probability of obtaining 3 or fewer heads out of 4 flips of this coin? 3 or fewer heads = 1 or more tails = .8704

1 or more heads = 2 or fewer tails = .9360

The Binomial Table A list of ALL the possible outcomes of N events when each event only has two outcomes.

The Critical Value of an Inferential Statistic

Critical Value of the statistic is the value that demarcates the outcomes that will allow us to make conclusions about the data.