introduction to bayesian computation

13
Math76 Summer 2020 Introduction to Bayesian Computation Lecture 3: Bayesian Inference 1 July 2020

Upload: others

Post on 22-May-2022

3 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Introduction to Bayesian Computation

Math76 Summer 2020

Introduction to Bayesian Computation

Lecture 3:Bayesian Inference1 July 2020

Page 2: Introduction to Bayesian Computation

Recap of Previous Lecture

X Y R R

A B A ER BER

P A prob of event A

RX c A

ProductJoint probability

PCA and B PCAA B PCA B

PLA 1B PCBpCBIA PCA

MarginalPCA PCA B t PCA a B

PCA PCAI B PCB PCA l B PC B

Page 3: Introduction to Bayesian Computation

IndependenceJ

A B are independent iff

PCA B PLA PCB

PCALB PCA iff A and B are independent

m X ly m x

BaYes'RpB pcaipgpcpg PCBM.lk

PCA1B prior

RBI evidence

likelihoodBayes Rule

Page 4: Introduction to Bayesian Computation

Case Study – Smoking and Lung Cancer

In the early 1950s, an NIH scientist named Jerome Cornfield was faced with an important question:

Question:

Why were so many people dying of lung cancer in 1950?

For more background, see

https://blogs.sas.com/content/iml/2013/03/18/biography-of-jerome-cornfield.html

Page 5: Introduction to Bayesian Computation

Formulation

PCHagan smoker Pcc is

P acsanY.FI smoker p Cc I s

PC ClsP PCc pCslc p

PCs pcsldp.cc PCs l c pfc

Pccl sPC

stp.cc P PC slc pccpCns1c pcc pC sl c pGc

Page 6: Introduction to Bayesian Computation

The Data

o

r atotal total Of

of cancerpatients i healthy patients

interviewed interviewed

Page 7: Introduction to Bayesian Computation

Likelihood Function – Breakout Exercise

Instructions:

1. As always, everyone should introduce themselves. To helpbreak the ice, tell everyone the probability that you’d havepancakes if you had to choose between pancakes and wa✏es.

2. As a group, use the Cornfield data on the previous slide todevelop a likelihood function. (i.e. P(S |C ) and P(¬S |C )).

3. Do you see any downfalls of using the data this way?

Page 8: Introduction to Bayesian Computation

Likelihood Function

PL s I c z ttsipatientategarytotal in patient category

5437 165543T Z G 97

nonsmokers in cancer patien catPC Slc

total in patient cat

165543 I 0.03

Page 9: Introduction to Bayesian Computation

Prior ProbabilitiesLung Cancer mortality rate in 1950: 40.1

100000

Chart courtesy of

https://canceratlas.cancer.org/the-burden/lung-cancer/

P c

PC c

o

Page 10: Introduction to Bayesian Computation

Posterior Probabilities

p.cc s PCSlc p

pCslc pCc tpCsl c pCnc

0.97 1040 00

7949 14010.97 l ooo

p Slac 794,9491401 ol

total in control

pccls

Page 11: Introduction to Bayesian Computation

Results

More history at

https://www.cdc.gov/tobacco/data˙statistics/sgr/history/index.htm

Yes lung cancer is partiallycaused by smoking

Page 12: Introduction to Bayesian Computation

Sequential Updates

Let's say I have 2 observations B and C

Bayes rule gives me

P A 1B cPCB CIA pea

I can then split the likelihood into two parts usingthe product rule

PCAI B cPCalB PCB

collecting terms we get

PCA1B c PCctAB2pCBlAjpcaNfnteioesajheatasthIsneisposxera.r

PLA1Bobtained in

PCCIB PCB heusual form of Baye's

PCCIA B p AIB ruleThis is like Bayes rule using

Page 13: Introduction to Bayesian Computation

pcc I gPCAIB as the prnor whenincorporating C

More on this next week