# Data from Boice, J. D., & Monson, R. R. (1977).
# Breast cancer in women after repeated fluoroscopic examinations of the chest.
# Journal of the National Cancer Institute, 59(3), 823-832.
# 41 cases of breast cancer during 28,010 person-years in the treatment group
# of women receiving X-ray fluoroscopy and 15 cases of breast cancer during
# 19 017 person-years in the control group.
no_cases <- c(41, 15)
no_years <- c(28010, 19017)
bayes.poisson.test(no_cases, no_years)
# Save the return value in order to inspect the model result further.
fit <- bayes.poisson.test(no_cases, no_years)
summary(fit)
plot(fit)
# MCMC diagnostics (should not be necessary for such a simple model)
diagnostics(fit)
# Print out the R code to run the model. This can be copy'n'pasted into
# an R-script and further modified.
model.code(fit)
Run the code above in your browser using DataLab