23
Binomial Binomial Distribution and Distribution and Applications Applications

Binomial Distribution and Applications

Embed Size (px)

DESCRIPTION

biomedik

Citation preview

Page 1: Binomial Distribution and Applications

Binomial Binomial Distribution and Distribution and

ApplicationsApplications

Page 2: Binomial Distribution and Applications

Binomial Probability Binomial Probability DistributionDistributionA binomial random variable A binomial random variable XX is defined to the is defined to the

number of “successes” in number of “successes” in nn independent trials independent trials where the where the P(“success”)P(“success”) = = pp is constant. is constant. Notation: Notation: X ~ BIN(n,p)X ~ BIN(n,p)

In the definition above notice the following In the definition above notice the following conditions need to be satisfied for a binomial conditions need to be satisfied for a binomial experiment:experiment:

1.1. There is a fixed number of There is a fixed number of n n trials carried out.trials carried out.2.2. The outcome of a given trial is either a The outcome of a given trial is either a

“success” “success” or “failure”. or “failure”.

3.3. The probability of success (The probability of success (pp) remains constant ) remains constant from trial to trial. from trial to trial.

4.4. The trials are independent, the outcome of a The trials are independent, the outcome of a trial is not affected by the outcome of any other trial is not affected by the outcome of any other trial.trial.

Page 3: Binomial Distribution and Applications

Binomial DistributionBinomial Distribution If If XX ~ BIN( ~ BIN(n, pn, p), then), then

wherewhere

.,...,1,0 )1()!(!

! )1()( nxppxnx

nppxn

xXP xnxxnx

psuccessPnx

nnnn

)"(" trials.in successes""

obtain to waysofnumber the x"choosen " xn

1 1! and 1 0! also ,1...)2()1(!

Page 4: Binomial Distribution and Applications

Binomial DistributionBinomial Distribution If If XX ~ BIN( ~ BIN(n, pn, p), then), then

E.g. when E.g. when n = 3 n = 3 and and p = .50 p = .50 there are 8 possible there are 8 possible equally likely outcomes (e.g. flipping a coin)equally likely outcomes (e.g. flipping a coin)

SSS SSF SFS FSS SFF FSF FFS SSS SSF SFS FSS SFF FSF FFS FFFFFF

X=3 X=2 X=2 X=2 X=1 X=1 X=1 X=3 X=2 X=2 X=2 X=1 X=1 X=1 X=0X=0

P(X=3)=1/8, P(X=2)=3/8, P(X=1)=3/8, P(X=3)=1/8, P(X=2)=3/8, P(X=1)=3/8, P(X=0)=1/8P(X=0)=1/8

Now let’s use binomial probability formula Now let’s use binomial probability formula instead…instead…

.,...,1,0 )1()!(!

! )1()( nxppxnx

nppxn

xXP xnxxnx

Page 5: Binomial Distribution and Applications

Binomial DistributionBinomial Distribution If If XX ~ BIN( ~ BIN(n, pn, p), then), then

E.g. when E.g. when n = 3n = 3,, p = .50 p = .50 find find P(X = 2)P(X = 2)

.,...,1,0 )1()!(!

! )1()( nxppxnx

nppxn

xXP xnxxnx

83or 375.)5)(.5(.3)5(.5.

23

)2(

ways31)12(

123!1 !2

!3)!23(!2

!323

12232

XP

SSF

SFS

FSS

Page 6: Binomial Distribution and Applications

Example: Treatment of Example: Treatment of Kidney Cancer Kidney Cancer

Suppose we have Suppose we have n = 40 n = 40 patients who patients who will be receiving an experimental therapy will be receiving an experimental therapy which is believed to be better than which is believed to be better than current treatments which historically current treatments which historically have had a 5-year survival rate of 20%, have had a 5-year survival rate of 20%, i.e. the probability of 5-year survival isi.e. the probability of 5-year survival isp = .20p = .20. .

Thus the number of patients out of 40 in Thus the number of patients out of 40 in our study surviving at least 5 years has a our study surviving at least 5 years has a binomial distribution, i.e. binomial distribution, i.e. X ~ X ~ BIN(40,.20)BIN(40,.20)..

Page 7: Binomial Distribution and Applications

Results and “The Results and “The Question”Question”

Suppose that using the new treatment Suppose that using the new treatment we find that 16 out of the 40 patients we find that 16 out of the 40 patients survive at least 5 years past diagnosis.survive at least 5 years past diagnosis.

Q: Does this result suggest that the new Q: Does this result suggest that the new therapy has a better 5-year survival rate therapy has a better 5-year survival rate than the current, i.e. is the probability than the current, i.e. is the probability that a patient survives at least 5 years that a patient survives at least 5 years greater than .20 or a 20% chance when greater than .20 or a 20% chance when treated using the new therapy?treated using the new therapy?

Page 8: Binomial Distribution and Applications

What do we consider in What do we consider in answering the question of answering the question of

interest?interest?We essentially ask ourselves the following:We essentially ask ourselves the following: If we assume that new therapy is no If we assume that new therapy is no

better than the current what is the better than the current what is the probability we would see these results by probability we would see these results by chance variation alone?chance variation alone?

More specifically what is the probability More specifically what is the probability of seeing 16 of seeing 16 or moreor more successes out of 40 successes out of 40 if the success rate of the new therapy if the success rate of the new therapy is .20 or 20% as well? is .20 or 20% as well?

Page 9: Binomial Distribution and Applications

Connection to BinomialConnection to Binomial This is a binomial experiment situation…This is a binomial experiment situation…

There are n = 40 patients and we are There are n = 40 patients and we are counting the number of patients that counting the number of patients that survive 5 or more years. The individual survive 5 or more years. The individual patient outcomes are independent and IF patient outcomes are independent and IF WE ASSUME the new method is NOT WE ASSUME the new method is NOT better then the probability of success is better then the probability of success is p p = .20= .20 or 20% for all patients. or 20% for all patients.

So So XX = # of “successes” in the clinical = # of “successes” in the clinical trial is binomial with trial is binomial with n = 40n = 40 and and p = .20,p = .20, i.e. i.e. X X ~ ~ BINBIN(40,.20)(40,.20)

Page 10: Binomial Distribution and Applications

Example: Treatment of Example: Treatment of Kidney Cancer Kidney Cancer

X ~ BIN(40,.20)X ~ BIN(40,.20), find the probability that , find the probability that exactly 16 patients survive at least 5 years.exactly 16 patients survive at least 5 years.

This requires some calculator gymnastics This requires some calculator gymnastics and some scratchwork! and some scratchwork!

Also, keep in mind we need to find the Also, keep in mind we need to find the probability of having probability of having 16 or more16 or more patients patients surviving at least 5 yrs. surviving at least 5 yrs.

001945.80.20.1640

)16( 2416

XP

Page 11: Binomial Distribution and Applications

Example: Treatment of Example: Treatment of Kidney Cancer Kidney Cancer

So we actually need to find:So we actually need to find:P(X P(X >> 16) = 16) = P(X = 16) + P(X = 17) + … + P(X = 16) + P(X = 17) + … + P(X = 40)P(X = 40)

++……+ +

= .002936= .002936 YIPES! YIPES!

001945.80.20.1640

)16( 2416

XP

000686.80.20.1740

)17( 2317

XP

080.20.4040

)40( 040

XP

Page 12: Binomial Distribution and Applications

Example: Treatment of Example: Treatment of Kidney Cancer Kidney Cancer

X ~ BIN(40,.20)X ~ BIN(40,.20), find the probability that , find the probability that 16 or more16 or more patients survive at least 5 patients survive at least 5 years.years.

USE COMPUTER!USE COMPUTER! Binomial Probability calculator in Binomial Probability calculator in

JMPJMP

probabilities are computed automatically for greater than or equal to and less than or equal to x.

Enter n = sample sizex = observed # of “successes”p = probability of “success”

Page 13: Binomial Distribution and Applications

Example: Treatment of Example: Treatment of Kidney Cancer Kidney Cancer

X ~ BIN(40,.20)X ~ BIN(40,.20), find the probability that , find the probability that 16 or more16 or more patients survive at least 5 patients survive at least 5 years.years.

USE COMPUTER!USE COMPUTER! Binomial Probability calculator in Binomial Probability calculator in

JMPJMP

The chance that we would see 16 or more patients out of 40 surviving at least 5 years if the new method has the same chance of success as the current methods (20%) is VERY SMALL, .0029!!!!

P(X > 16) = .0029362

Page 14: Binomial Distribution and Applications

ConclusionConclusion Because it is high unlikely (p = .0029) that Because it is high unlikely (p = .0029) that

we would see this many successes in a we would see this many successes in a group group 4040 patients if the new method had patients if the new method had the same probability of success as the the same probability of success as the current method we have to make a choice, current method we have to make a choice, either …either …

A)A) we have obtained a very rare result by we have obtained a very rare result by dumb luck. dumb luck.

ORORB)B) our assumption about the success rate of our assumption about the success rate of

the new method is wrong and in actuality the new method is wrong and in actuality the new method has a better than 20% 5-the new method has a better than 20% 5-year survival rate making the observed year survival rate making the observed result more plausible.result more plausible.

Page 15: Binomial Distribution and Applications

Example: Sign TestExample: Sign Test A study evaluated hepatic arterial A study evaluated hepatic arterial

infusion of floxuridine and cisplatin for infusion of floxuridine and cisplatin for the treatment of liver metastases of the treatment of liver metastases of colorectral cancer. colorectral cancer.

Performance scores for 29 patients Performance scores for 29 patients were recorded were recorded beforebefore and and afterafter infusion. infusion.

Is there evidence that patients had a Is there evidence that patients had a better performance score after infusion?better performance score after infusion?

Page 16: Binomial Distribution and Applications

Example: Sign TestExample: Sign TestPatientPatient

Before Before (B) (B) InfusionInfusion

After After (A) (A) InfusionInfusion

DifferenDifference (A – ce (A – B)B)

PatientPatientBefore Before (B) (B) InfusionInfusion

After After (A) (A) InfusionInfusion

DifferenDifference (A – ce (A – B)B)

11 22 11 -1-1 1616 00 00 0022 00 00 00 1717 00 33 3333 00 00 00 1818 22 33 1144 11 00 -1-1 1919 22 33 1155 33 33 00 2020 33 22 -1-166 11 11 00 2121 00 44 4477 11 33 22 2222 00 33 3388 00 00 00 2323 11 22 1199 00 00 00 2424 00 33 331010 11 00 -1-1 2525 00 22 221111 11 11 00 2626 11 11 001212 11 11 00 2727 33 33 001313 22 11 -1-1 2828 11 22 111414 33 11 -2-2 2929 00 22 221515 00 00 00

Page 17: Binomial Distribution and Applications

Sign TestSign Test The sign test looks at the number of (+) The sign test looks at the number of (+)

and (-) differences amongst the nonzero and (-) differences amongst the nonzero paired differences. paired differences.

A preponderance of +’s or –’s can A preponderance of +’s or –’s can indicate that some type of change has indicate that some type of change has occurred.occurred.

If in reality there is no change as a result If in reality there is no change as a result of infusion we expect +’s and –’s to be of infusion we expect +’s and –’s to be equally likely to occur, i.e. P(+) = P(-) equally likely to occur, i.e. P(+) = P(-) = .50 and the number of each observed = .50 and the number of each observed follows a binomial distribution.follows a binomial distribution.

Page 18: Binomial Distribution and Applications

Example: Sign TestExample: Sign Test Given these results do we have Given these results do we have

evidence that performance scores of evidence that performance scores of patients generally improves patients generally improves following infusion?following infusion?

Need to look at how likely the Need to look at how likely the observed results are to be produced observed results are to be produced by chance variation alone.by chance variation alone.

Page 19: Binomial Distribution and Applications

Example: Sign Test Example: Sign Test PatientPatient

Before Before (B) (B) InfusionInfusion

After After (A) (A) InfusionInfusion

DifferenDifference (A – ce (A – B)B)

PatientPatientBefore Before (B) (B) InfusionInfusion

After After (A) (A) InfusionInfusion

DifferenDifference (A – ce (A – B)B)

11 22 11 -1 -1 1616 00 00 0022 00 00 00 1717 00 33 3333 00 00 00 1818 22 33 1144 11 00 -1-1 1919 22 33 1155 33 33 00 2020 33 22 -1-166 11 11 00 2121 00 44 4477 11 33 22 2222 00 33 3388 00 00 00 2323 11 22 1199 00 00 00 2424 00 33 331010 11 00 -1-1 2525 00 22 221111 11 11 00 2626 11 11 001212 11 11 00 2727 33 33 001313 22 11 -1-1 2828 11 22 111414 33 11 -2-2 2929 00 22 221515 00 00 00

-

-

-

--

-

+

+++

+++++

++

17 nonzeros differences, 11 +’s 6 –’s

Page 20: Binomial Distribution and Applications

Example: Sign TestExample: Sign Test If there is truly no change in performance as a If there is truly no change in performance as a

result of infusion the number of +’s has a result of infusion the number of +’s has a binomial distribution with n = 17 and binomial distribution with n = 17 and pp = P(+) = .50. = P(+) = .50.

We have observed 11 +’s amongst the 17 non-We have observed 11 +’s amongst the 17 non-zero performance differences.zero performance differences.

How likely are we to see 11 or more +’s out 17? How likely are we to see 11 or more +’s out 17? P(X P(X >> 11) = .166 for a binomial 11) = .166 for a binomial n = 17, p = .50n = 17, p = .50

There is 16.6% chance we would see this many There is 16.6% chance we would see this many improvements by dumb luck alone, therefore we improvements by dumb luck alone, therefore we are not convinced that infusion leads to are not convinced that infusion leads to improvement improvement (Remember less than .05 or a 5% chance is what (Remember less than .05 or a 5% chance is what we are looking for “statistical significance”)we are looking for “statistical significance”)

Page 21: Binomial Distribution and Applications

Example 2: Sign TestExample 2: Sign TestResting Energy Expenditure (REE) for Resting Energy Expenditure (REE) for

Patient with Cystic FibrosisPatient with Cystic Fibrosis A researcher believes that patients with A researcher believes that patients with

cystic fibrosis (CF) expend greater energy cystic fibrosis (CF) expend greater energy during resting than those without CF. To during resting than those without CF. To obtain a fair comparison she matches 13 obtain a fair comparison she matches 13 patients with CF to 13 patients without CF patients with CF to 13 patients without CF on the basis of age, sex, height, and weight. on the basis of age, sex, height, and weight. She then measured there REE for each pair She then measured there REE for each pair of subjects and compared the results.of subjects and compared the results.

Page 22: Binomial Distribution and Applications

Example 2: Sign TestExample 2: Sign Test

There are

11 +’s & 2 –’s

out of n = 13 paired differences.

Page 23: Binomial Distribution and Applications

Example 2: Sign TestExample 2: Sign Test

The probability of seeing this many +’s is small. We conclude that when comparing individuals with cystic fibrosis to healthy individuals of the same gender and size that in general those with CF have larger resting energy expenditure (REE) (p = .0112).