Announcements - McMaster Universityms.mcmaster.ca/~clemene/1LT3/lectures/1lt3_sections101314.pdf ·...
Transcript of Announcements - McMaster Universityms.mcmaster.ca/~clemene/1LT3/lectures/1lt3_sections101314.pdf ·...
AnnouncementsTopics:
IntheProbabilityandStatisticsmodule:- Section10:TheBinomialDistribution- Section13:ContinuousRandomVariables- Section14:TheNormalDistribution
ToDo:- WorkonAssignmentsandSuggestedPracticeProblemsassignedonthewebpageundertheSCHEDULE+HOMEWORKlink
BernoulliExperimentandBernoulliRandomVariable
ABernoulliexperimentisarandomexperimentwithonlytwopossibleoutcomes:successorno-success.Definition:Adiscreterandomvariablethattakesonthevalue1(“success”)withprobabilitypandthevalue0(“no-success”)withprobability1-piscalledaBernoullirandomvariable.
BernoulliExperimentandBernoulliRandomVariable
Example:ElephantPopulationwithImmigrationConsiderapopulationofelephantsptmodelledbyDefineaBernoulliexperimentanddeterminetheprobabilitymassfunctionforthecorrespondingBernoullirandomvariable.
€
€
pt+1 = pt + It where It =10 with a 90% chance0 with a 10% chance" # $
TheBinomialDistribution
LetNcountthenumberofsuccessesinnrepetitionsofthesameBernoulliexperiment,whereoutcomesareindependentandpistheprobabilityofsuccessinasingleexperiment.ThenNisabinomiallydistributedrandomvariableandwewrite
€
€
N ~ B(n, p)
TheBinomialDistribution
Definethebinomialprobabilitydistributionbywhereistheprobabilityofexactlyksuccessesinnrepetitionsofthesameexperiment,wherepistheprobabilityofsuccessinasingleexperiment.
€
€
b(k, n; p) = P(N = k)
€
b(k, n; p)
TheBinomialDistribution
Example:ElephantPopulationwithImmigrationConsiderthepopulationofelephantsptmodelledbywheret=0,1,2,…ismeasuredinyears.LetNcountthenumberoftimesimmigrationoccursoverthenext3years.DeterminetheprobabilitymassfunctionforN.
€
€
pt+1 = pt + It where It =10 with a 90% chance0 with a 10% chance" # $
TheBinomialDistribution
Theprobabilityofksuccessesinnexperimentsis(numberofwaysofobtainingksuccessesinnexperiments)*(probabilityofsuccess)k*(probabilityofno-success)n-ki.e.,
€
€
b(k, n; p) = C(n,k)pk (1− p)n−k
Counting101
Supposewehaveaselectionof10books.1. Howmanydifferentorderings(permutations)canyoureadthemin?
2. Howmanydifferentorderingscanyouread3in?
3. Supposeyouwanttoreadthreebooksbutyoudon’tcareabouttheorderinwhichyoureadthem.Howcanyouchoose3booksfrom10?
Counting101
Now,replace“10books”by“nexperiments”and“choose3books”by“choosekexperimentsinwhichthereisasuccess”.ThenumbersofwayswecanhaveksuccessesinnrepetitionsoftheexperimentisnCk.So,C(n,k)=nCk.
€
TheProbabilityDistributionoftheBinomialVariable
Theorem:TheprobabilitydistributionofthebinomialvariableNisgivenbywhereNcountsthenumberofsuccessesinnindependentrepetitionsofthesameBernoulliexperimentandpistheprobabilityofsuccess.
€
€
P(N = k) = b(k, n; p) =nk"
# $ %
& ' pk (1− p)n−k
TheProbabilityDistributionoftheBinomialVariable
Example:CoinTossWhatistheprobabilityofexactly7tailsin10tosses?
€
TheProbabilityDistributionoftheBinomialVariable
Example:ElephantPopulationwithImmigrationConsiderapopulationofelephantsptmodelledbySupposethatinitiallythereare80elephants.Whatistheprobabilitythattherewillbemorethan300elephantsafter25years?
€
€
pt+1 = pt + It where It =10 with a 90% chance0 with a 10% chance" # $
TheMeanandVarianceoftheBinomialDistribution
MeanandVarianceoftheBinomialRandomVariableN:
€
E(N ) = npVar(N ) = np(1− p)
TheMeanandVarianceoftheBinomialDistribution
Example:ElephantPopulationwithImmigrationConsiderapopulationofelephantsptmodelledbySupposethatinitiallythereare80elephants.Whatistheexpectedvalueofthepopulationafter25years?Whatisthestandarddeviation?
€
€
pt+1 = pt + It where It =10 with a 90% chance0 with a 10% chance" # $
ContinuousRandomVariables
Definition:Arandomvariablethattakesonacontinuumofvaluesiscalledacontinuousrandomvariable.
ContinuousRandomVariables
Example:DistributionsofLengthsofBoaConstrictorsTheboaconstrictorisalargespeciesofsnakethatcangrowtoanywherebetween1mand4minlength.LetLbethecontinuousrandomvariablethatmeasuresthelengthofasnake.
L : S→ [1, 4]
ContinuousRandomVariables
Thelengthsof500boasarerecordedbelow:Note:relativefrequency=frequency/500=probability
ContinuousRandomVariablesHistogramforProbabilityMass:Theprobabilitythatarandomlyselectedboaisbetween2.5mand3minlengthistheheightoftherectangleover[2.5,3),i.e.,0.36.
ContinuousRandomVariables
Todrawahistogramrepresentingprobabilitydensity,were-labeltheverticalaxissothattheprobabilitythatLbelongstoanintervalistheareaoftherectangleabovethatinterval.
ContinuousRandomVariables
Note: probabilitymass lengthofinterval
=probabilitydensity
ContinuousRandomVariables
Forexample,considertheinterval[2.5,3).TheprobabilitythatLfallsinthisrangeis0.36.Now,wewantthisvaluetobetheareaoftherectangleover[2.5,3),soprobabilitydensity(height)=0.36/(3-2.5)=0.72
ContinuousRandomVariables
HistogramforProbabilityDensity:Theprobabilitythatarandomlyselectedboaisbetween2.5mand3minlengthistheareaoftherectangleabove[2.5,3),i.e.0.36.
ContinuousRandomVariablesTogetamorepreciseprobabilitymass(ordensity)function,wedivide[1,4]intosmallersubintervals:.
ContinuousRandomVariables
Aswecontinuetoincreasethenumberofsubintervals,weobtainamoreandmorerefinedhistogram..
ContinuousRandomVariablesRiemannSum:Theprobabilitythatarandomlychosenboaisbetween1.75mand2minlengthisthesumoftheareasoftherectanglesovertheinterval[1.75,2).
ContinuousRandomVariables
Toobtaintheprobabilitydensityfunction,weletthelengthoftheintervalsapproach0andthenumberofrectanglesapproach∞..
ProbabilityDensityFunctions
Definition:DefiningPropertiesofaPDFAssumethattheintervalIrepresentstherangeofacontinuousrandomvariableX.Afunctionf(x)canbeaprobabilitydensityfunctionif(1)(2)
€
f (x) ≥ 0 for all x ∈ I.
€
f (x)dx =1.I∫
ProbabilityDensityFunctions
Example:Showthatcouldbeaprobabilitydensityfunctionforsomecontinuousrandomvariableon[0,∞).
€
f (x) =2
π (1+ x 2)
CalculatingProbabilitiesForacontinuousrandomvariable,wecalculatetheprobabilitythatarandomvariablebelongstoanintervalofrealnumbers.TheprobabilitythatanoutcomeXisbetweenaandbistheareaunderthegraphoff(x)on[a,b]:
€
P(a ≤ X ≤ b) = f (x)dxa
b
∫
CalculatingProbabilities
Theprobabilitythatanoutcomeisequaltoaparticularvalueiszero.Forthisreason,includingorexcludingtheendpointsofanintervaldoesnotaffecttheprobability,i.e.,
€
P(a ≤ X ≤ a) = f (x)dx = 0a
a
∫
€
P(a ≤ X ≤ b) = P(a ≤ X < b) = P(a < X ≤ b) = P(a < X < b)
CalculatingProbabilitiesExample#32:Thedistancebetweenaseedandtheplantitcamefromismodelledbythedensityfunctionwherexrepresentsthedistance(inmetres),Whatistheprobabilitythataseedwillbefoundfartherthan5mfromtheplant?
€
f (x) =2
π (1+ x 2)
€
x ∈ [0,∞).
CumulativeDistributionFunction
Definition:Supposethatf(x)isaprobabilitydensityfunctiondefinedonaninterval[a,b].ThefunctionF(x)definedbyforallxin[a,b]iscalledacumulativedistributionfunctionoff(x). €
F(x) = P(X ≤ x) = f (t)dta
x
∫
CumulativeDistributionFunctionExample#30(modified):Supposethatthelifetimeofaninsectisgivenbytheprobabilitydensityfunctionwheretismeasuredindays,(a)Determinethecorrespondingcumulativedistributionfunction,F(t).(b)Findtheprobabilitythattheinsectwilllivebetween5-7days.
€
f (t) = 0.2e−0.2t
€
t ∈ [0,∞).
CumulativeDistributionFunctionExample#30(modified):
PROBABILITY�DENSITY�FUNCTION�F�T� � � ���������CUMULATIVE�DISTRIBUTION�FUNCTION�&�T
CumulativeDistributionFunction
PropertiesoftheCDF:Assumethatfisaprobabilitydensityfunction,definedandcontinuousonaninterval[a,b].Theleftendacouldbearealnumberornegativeinfinity;therightendbcouldbearealnumberorinfinity.DenotebyFtheassociatedcumulativedistributionfunction.Then(1)(2)iscontinuousandnon-decreasing.(3)
€
0 ≤ F(x) ≤1 for all x ∈ [a,b].
€
F(x)
€
limx→a
F(x) = 0 and limx→b
F(x) =1.
TheMeanandtheVarianceDefinition:LetXbeacontinuousrandomvariablewithprobabilitydensityfunctionf(x),definedonaninterval[a,b].Themean(ortheexpectedvalue)ofXisgivenbyThevarianceofXis €
µ = E(X) = x f (x)dxa
b
∫
€
var(X) = E (X −µ)2[ ] = (x −µ)2 f (x)dxa
b
∫
TheMeanandtheVarianceExample#24:ConsiderthecontinuousrandomvariableXgivenbytheprobabilitydensityfunctionFindtheprobabilitythatthevaluesofXareatleastonestandarddeviationabovethemean.
€
f (x) = 0.3+ 0.2x for 0 ≤ x ≤ 2.
TheNormalDistribution
Thenormaldistributionisthemostimportantcontinuousdistributionasitcanbeusedtomodelmanyphenomenainavarietyoffields.Manymeasurementsforlargesamplesizesaresaidtobe‘normallydistributed’.Forexample,heightsoftrees,IQscores,anddurationofpregnancyareallnormallydistributedmeasurements.
TheNormalDistribution
Definition:AcontinuousrandomvariableXhasanormaldistribution(orisdistributednormally)withmeanandvariance,denotedby,ifitsprobabilitydensityfunctioniswhere
€
f (x) =1
σ 2πe−(x−µ )2
2σ 2
€
µ
€
σ 2
€
X ~ N(µ,σ 2)
€
x ∈ (−∞,∞).
TheNormalDistribution
Thegraphoftheprobabilitydensityfunctionofthenormaldistribution(alsoknownastheGaussiandistribution)isabell-shapedcurve.
PropertiesoftheNormalDistributionDensityFunction
Theorem:Theprobabilitydensityfunctionf(x)ofthenormaldistributionsatisfiesthefollowingproperties:(a) f(x)issymmetricwithrespecttotheverticalline(b) f(x)isincreasingforanddecreasingforIthasalocal(alsoglobal)maximumvalueat(c)Theinflectionpointsoff(x)are(d)
€
limx→−∞
f (x) = limx→∞
f (x) = 0
€
x = µ.
€
x < µ
€
x > µ.
€
1 σ 2π
€
x = µ ±σ .
€
x = µ.
CalculatingProbabilities
IfXisanormallydistributedcontinuousrandomvariablewithmeanandvariancethen
€
P(a ≤ X ≤ b) = f (x)dx =a
b
∫ 1σ 2π
e−(x−µ )2
2σ 2 dxa
b
∫€
µ
€
σ 2,
CalculatingProbabilities
Thisintegralcannotbeevaluatedwithoutestimationtechniques,suchasusingaTaylorpolynomialtoapproximatef(x).Toevaluatethisintegral,wereduceageneralnormaldistributiontoaspecialnormaldistribution,calledthestandardnormaldistribution,andthenusetablesofestimatedvalues.
StandardNormalDistribution
Definition:Thestandardnormaldistributionisthenormaldistributionwithmean0andvariance1;insymbols,itisN(0,1).Itsprobabilitydensityfunctionisgivenbyforall €
f (x) =12π
e−x 2
2
€
x ∈ (−∞,∞).
StandardNormalDistribution
WeusethesymbolZtodenotethecontinuousrandomvariablethathasthestandardnormaldistribution;i.e.,
€
Z ~ N(0,1).
StandardNormalDistribution
ThecumulativedistributionfunctionofZisgivenby
€
F(z) = f (x)dx =−∞
z
∫ 12π
e−x 2
2 dx−∞
z
∫
€
F(−z) =1− F(z)
TheNormalandtheStandardNormalDistributions
Theorem:AssumethatTherandomvariableZ=hasthestandardnormaldistribution,i.e.,Sothen
€
X ~ N(µ,σ 2).
€
Z ~ N(0,1).
€
Z = (X −µ) σ
€
P(a ≤ X ≤ b) = P(a −µσ
≤ Z ≤ b −µσ).
TheNormalandtheStandardNormalDistributions
Inwords,theareaunderthenormaldistributiondensityfunctionbetweenaandbisequaltotheareaunderthestandardnormaldensityfunctionbetweenand
€
(a −µ) /σ
€
(b −µ) /σ .
TheNormalandtheStandardNormalDistributions
Example#10:Example#30:
€
Let X ~ N(−2,4); find P(−3 ≤ X ≤1).
€
Let X ~ N(2,144); find a value of x that satisfies P(X > x) = 0.3.
Application
Example:Intelligencequotient(IQ)scoresaredistributednormallywithmean100andstandarddeviation15.(a) WhatpercentageofthepopulationhasanIQscorebetween85and115?
(b) WhatpercentageofthepopulationhasanIQabove140?
(c) WhatIQscoredo90%ofpeoplefallunder?
68-95-99.7Rule
IfXisacontinuousrandomvariabledistributednormallywithmeanandstandarddeviation,then
€
P(µ −σ ≤ X ≤ µ +σ) = 0.683P(µ − 2σ ≤ X ≤ µ + 2σ) = 0.955P(µ − 3σ ≤ X ≤ µ + 3σ) = 0.997€
µ
€
σ
68-95-99.7Rule
Inwords,foranormallydistributedrandomvariable:68.3%ofthevaluesfallwithinonestandarddeviationofthemean.95.5%ofthevaluesfallwithintwostandarddeviationsofthemean.99.7%ofthevaluesfallwithinthreestandarddeviationsofthemean.
Application
Example14.7:TheLengthsofPregnanciesThelengthsofhumanpregnancies(measuredindaysfromconceptiontobirth)canbeapproximatedbythenormaldistributionwithameanof266daysandastandarddeviationof16days.
Application
Example14.7:TheLengthsofPregnanciesThus,about68%ofpregnancieslastbetween266-16=250daysand266+16=282days.About95.5%ofpregnancieslastbetween266-2x16=234daysand266+2x16=298days,andabout99.7%ofpregnancieslastbetween266-3x16=218daysand266+3x16=314days.