没有合适的资源?快使用搜索试试~ 我知道了~
资源推荐
资源详情
资源评论
2016/11/7 HowBayesianinferenceworks
http://brohrer.github.io/how_bayesian_inference_works.html 1/18
HowBayesianinferenceworks
DataScienceandRobotsBlog
Gettheslides.
Bayesianinferenceisawaytogetsharperpredictionsfromyourdata.It’sparticularlyusefulwhenyoudon’thaveasmuch
dataasyouwouldlikeandwanttojuiceeverylastbitofpredictivestrengthfromit.
Althoughitissometimesdescribedwithreverence,Bayesianinferenceisn’tmagicormystical.Andeventhoughthemath
underthehoodcangetdense,theconceptsbehinditarecompletelyaccessible.Inbrief,Bayesianinferenceletsyoudraw
strongerconclusionsfromyourdatabyfoldinginwhatyoualreadyknowabouttheanswer.
BayesianinferenceisbasedontheideasofThomasBayes,anonconformistPresbyterianministerinLondonabout300
yearsago.Hewrotetwobooks,oneontheology,andoneonprobability.HisworkincludedhisnowfamousBayesTheorem
inrawform,whichhassincebeenappliedtotheproblemofinference,thetechnicaltermforeducatedguessing.The
popularityofBayes'ideaswasaidedimmeasurablybyanotherminister,RichardPrice.Hesawtheirsignificance,refined
themandpublishedthem.ItwouldbemoreaccurateandhistoricallyjusttocallBayes'TheoremtheBayesPriceRule.
Bayesianinferenceatthemovies
2016/11/7 HowBayesianinferenceworks
http://brohrer.github.io/how_bayesian_inference_works.html 2/18
Imagineyouareatthemoviesandafellowmoviegoerdropstheirticket.Youwanttogettheirattention.Thisiswhatthey
looklikefrombehind.Youcan’ttelltheirgender,onlythattheyhavelonghair.Doyoucallout“Excusemema’am!”or
“Excusemesir!”Givenwhatyouknowaboutmen’sandwomen’shairstylesinyourarea,youmightassumethatthisisa
woman.(Inthisoversimplification,thereareonlytwohairlengthsandgenders.)
Nowconsideravariationofthesituationwherethispersonisstandinginlineforthemen’srestroom.Withthisadditional
pieceofinformation,youwouldprobablyassumethatthisisaman.Thisuseofcommonsenseandbackgroundknowledge
issomethingthatwedowithoutthinking.Bayesianinferenceisawaytocapturethisinmathsothatwecanmakemore
accuratepredictions.
Toputnumberstoourcinemadilemma,let’sassumethatthereareabouthalfmenandhalfwomenatthetheater.Outof
100people,50aremen,50arewomen.Outofthewomen,halfhavelonghair(25)andtheother25haveshorthair.Outof
themen,48haveshorthairand2havelonghair.Sincethereare25longhairedwomenand2longhairedmen,guessing
thattheticketownerisawomanisasafebet.
2016/11/7 HowBayesianinferenceworks
http://brohrer.github.io/how_bayesian_inference_works.html 3/18
Outof100peopleinthemen’srestroomline,however,thereare98menandtwowomenkeepingtheirpartnerscompany.
Halfthewomenstillhavelonghairandhalfhaveshorthair,butheretherearejustoneofeach.Theproportionsofmenwith
longandshorthairarethesametoo,butsincethereare98ofthem,therearenow94withshorthairand4withlong.Since
thereis1womanwithlonghairandfourmen,nowthesafebetisthattheticketownerisaman.Thisisaconcreteexample
oftheprincipleunderlyingBayesianinference.Knowingakeypieceofinformationbeforehandthattheticketownerisin
themen’srestroomlineallowsustomakeabetterpredictionaboutthem.
ToclearlytalkaboutBayesianinference,itisworthourtimetoreallyclearlydefineourideas.Unfortunately,thisrequires
usingmath.We’llavoidgoingdeeperthanwehaveto,butstickwithmeforafewmoreparagraphsanditwillpayoff.Tolay
ourfoundation,weneedtoquicklymentionfourconcepts:probabilities,conditionalprobabilities,jointprobabilitiesand
marginalprobabilities.
Probabilities
Theprobabilityofathinghappeningisthenumberofwaysthatthingcanhappendividedbythetotalnumberofthingsthat
canhappen.Theprobabilitythatamoviegoerisawomanis50womendividedby100moviegoers,.5or50%.Thesame
holdsformen.
2016/11/7 HowBayesianinferenceworks
http://brohrer.github.io/how_bayesian_inference_works.html 4/18
Thesituationinmen’srestroomlinebreaksdownto.02forwomen,.98formen.
Conditionalprobabilities
Conditionalprobabilitiesanswerthequestion“IfIknowthatapersonisawoman,whatistheprobabilitythatshehaslong
hair?”Conditionalprobabilitiesarecalculatedthesamewayasstraightprobabilities,buttheyjustlookatasubsetofallthe
examplesthosemeetingacertaincondition.Inthiscase,P(longhair|woman),theconditionalprobabilitythatsomeone
haslonghair,giventhatsheisawoman,isthenumberofwomenwithlonghair,dividedbythetotalnumberofwomen.This
turnsouttobe.5,whetherweareconsideringthemen’srestroomline,orthetheateroverall.
剩余17页未读,继续阅读
资源评论
weixin_40191861_zj
- 粉丝: 84
- 资源: 1万+
上传资源 快速赚钱
- 我的内容管理 展开
- 我的资源 快来上传第一个资源
- 我的收益 登录查看自己的收益
- 我的积分 登录查看自己的积分
- 我的C币 登录后查看C币余额
- 我的收藏
- 我的下载
- 下载帮助
最新资源
资源上传下载、课程学习等过程中有任何疑问或建议,欢迎提出宝贵意见哦~我们会及时处理!
点击此处反馈
安全验证
文档复制为VIP权益,开通VIP直接复制
信息提交成功