Suppose that the number of new cases of a medical condition observed each week can be modelled using a negative binomial distribution with parameters q and r, q is unknown, while r is known. We observe n weeks’ worth of data, and the number of cases each week was y1, . . . , yn. (a) Show that a beta distribution provides a conjugate prior distribution for q, and find the posterior distribution with such a prior. The column in the exercise 2 dataset labelled y, contains the observed data y1, . . . , yn. Assume that r is equal to 3. (b)  With a uniform prior distribution for q on the interval [0, 1], what is the posterior distribution for q (including the numerical value of the parameters)? (c)  What is the posterior mean? (d)  Use R to find the posterior median and a 95% credible interval for q.

College Algebra
7th Edition
ISBN:9781305115545
Author:James Stewart, Lothar Redlin, Saleem Watson
Publisher:James Stewart, Lothar Redlin, Saleem Watson
Chapter9: Counting And Probability
Section9.3: Binomial Probability
Problem 2E: If a binomial experiment has probability p success, then the probability of failure is...
icon
Related questions
Question

Suppose that the number of new cases of a medical condition observed each week can be modelled using a negative binomial distribution with parameters q and r, q is unknown, while r is known.

We observe n weeks’ worth of data, and the number of cases each week was y1, . . . , yn.

(a) Show that a beta distribution provides a conjugate prior distribution for q, and find the posterior distribution with such a prior.

The column in the exercise 2 dataset labelled y, contains the observed data y1, . . . , yn.

Assume that r is equal to 3.

(b)  With a uniform prior distribution for q on the interval [0, 1], what is the posterior distribution for q (including the numerical value of the parameters)?

(c)  What is the posterior mean?

(d)  Use R to find the posterior median and a 95% credible interval for q.

Expert Solution
steps

Step by step

Solved in 3 steps with 14 images

Blurred answer
Recommended textbooks for you
College Algebra
College Algebra
Algebra
ISBN:
9781305115545
Author:
James Stewart, Lothar Redlin, Saleem Watson
Publisher:
Cengage Learning
College Algebra
College Algebra
Algebra
ISBN:
9781337282291
Author:
Ron Larson
Publisher:
Cengage Learning