Asked prior to a study of a new chemotherapy, an oncologist said that she would expect
50% of patients respond. Then, you obtain a sample of 20 patients treated, 14 respond.
Answer each of the following questions. You have to show all your work to get full credit.
a) Let π denote the unknown proportion of patients that respond to new chemotherapy.
Use a U (0, 1) prior for π. Find the posterior distribution of π given y. Provide its
parameters, explicitly. Justify your answer.
Alternative 1:
Posterior distribution is proportional to (prior distribution)(likelihood)
Alternative 2:
Updating rules:
(for conjugate priors, uniform and beta)
b) Summarize the posterior distribution by its first two moments (i.e. mean and variance).
If you remember the formulas, write them and use them.
c) Using your posterior distribution, find P [π > 0.7]. Please, show all your work
By hand using normal approx.
1-pbeta(0.7,15,7)
General Beta Prior
Prior is instead of uniform
General update rule:
Choosing Parameters to Match Prior Beliefs
Strategy 1: Graph some beta densities until you find one that matches your beliefs
Strategy 2: Not that prior is equivalent to the information contained in a previously observed data set. Based on update rules successes and failures.
note:
Strategy 3: Solve for values of and that give:
the desired expectation
the desired equivalent prior sample size which for a is
Strategy 4: chose and that reflect a prior probability interval that reflects your belief about
can look at credible intervals
Strategy 5: Solve for values of and that give:
the desired expectation
the desired variance
(expectation from sample equivalent same size is here)
Assumptions: Parameter: Likelihood: is Posterior:
Expectation Based On Sample
note:
this is why we have the idea that
Posterior Predictive Distribution
In general if bayesian analysis has been done to estimate a using prior and a dataset with successes in a sample size .
Deriving beta-binomial
Example 2
Suppose a drug has an unknown true response rate π. Assume a Bernoulli process. Answer each of the following questions. You have to show all your work to get full credit.
a) Suppose that previous experience with similar compounds has suggested a response rate with an expectation around and variance . Find a Beta prior for π with mean and variance . Provide parameters of distribution, explicitly. If you can’t find it, use a prior to get partial credit.
b) Suppose that we observe 15 positive responses (successes) out of 20 patients. Find the posterior distribution of π given y. Provide its parameters, explicitly. Justify your answer.
c) Summarize the posterior distribution by its first two moments (i.e. mean and variance).
d) Compute a 95% credible interval for π using the Normal approximation.
qbeta(0.025, 19, 11)
note: this is based on the equal-tail posterior credible sets however the highest posterior density region is the shortest possible interval containing the desired probability. This may no be symmetrical.
Example 3
Suppose that a uniform prior is placed on the proportion π (that denotes the unknown proportion of patients that respond to a new chemotherapy), and that from a random sample of 10 patients treated, 7 respond. Also suppose that a new group of 5 patients is planning to receive this new chemotherapy. Let denote the number in this new sample who respond. Find the posterior predictive probability that and .
simple example:
Predictive posterior distribution when