Question: Consider a univariate normal model with mean and variance . Suppose we use a Beta(2,2) prior for (somehow we know is between zero and one)

Consider a univariate normal model with mean and variance . Suppose we use a Beta(2,2) prior for (somehow we know is between zero and one) and a log-normal(1,10) prior for (recall that if a random variable X is log-normal(m, v) then logX is N(m, v)). Assume a priori that and are independent. Implement a Metropolis-Hastings algorithm to evaluate the posterior distribution of and . Remember that you have to jointly accept or reject and . Also compute the posterior probability that is bigger than 0.5.

Here are the data:

2.3656491

2.4952035

1.0837817

0.7586751

0.8780483

1.2765341

1.4598699

0.1801679

-1.0093589

1.4870201

-0.1193149

0.2578262

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Mathematics Questions!