資源描述:
《think bayes bayes’s theorem》由會(huì)員上傳分享,免費(fèi)在線閱讀,更多相關(guān)內(nèi)容在工程資料-天天文庫(kù)。
1、CHAPTER1Bayes’sTheoremConditionalprobabilityThefundamentalideabehindallBayesianstatisticsisBayes’stheorem,whichissur‐prisinglyeasytoderive,providedthatyouunderstandconditionalprobability.Sowe’llstartwithprobability,thenconditionalprobability,thenBayes’stheorem,andontoBayesianstat
2、istics.Aprobabilityisanumberbetween0and1(includingboth)thatrepresentsadegreeofbeliefinafactorprediction.Thevalue1representscertaintythatafactistrue,orthatapredictionwillcometrue.Thevalue0representscertaintythatthefactisfalse.Intermediatevaluesrepresentdegreesofcertainty.Thevalue0
3、.5,oftenwrittenas50%,meansthatapredictedoutcomeisaslikelytohappenasnot.Forexample,theprobabilitythatatossedcoinlandsfaceupisverycloseto50%.Aconditionalprobabilityisaprobabilitybasedonsomebackgroundinformation.Forexample,IwanttoknowtheprobabilitythatIwillhaveaheartattackinthenexty
4、ear.AccordingtotheCDC,“Everyyearabout785,000Americanshaveafirstcoronaryattack(http://www.cdc.gov/heartdisease/facts.htm).”TheU.S.populationisabout311million,sotheprobabilitythatarandomlychosenAmericanwillhaveaheartattackinthenextyearisroughly0.3%.ButIamnotarandomlychosenAmerican.
5、Epidemiologistshaveidentifiedmanyfac‐torsthataffecttheriskofheartattacks;dependingonthosefactors,myriskmightbehigherorlowerthanaverage.Iammale,45yearsold,andIhaveborderlinehighcholesterol.Thosefactorsincreasemychances.However,IhavelowbloodpressureandIdon’tsmoke,andthosefactorsdec
6、reasemychances.1Pluggingeverythingintotheonlinecalculatorathttp://hp2010.nhlbihin.net/atpiii/calculator.asp,Ifindthatmyriskofaheartattackinthenextyearisabout0.2%,lessthanthenationalaverage.Thatvalueisaconditionalprobability,becauseitisbasedonanumberoffactorsthatmakeupmy“condition
7、.”TheusualnotationforconditionalprobabilityispAB,whichistheprobabilityofAgiventhatBistrue.Inthisexample,ArepresentsthepredictionthatIwillhaveaheartattackinthenextyear,andBisthesetofconditionsIlisted.ConjointprobabilityConjointprobabilityisafancywaytosaytheprobabilitythattwothings
8、aretrue.IwritepAandBtomeantheprobability