Question: Need a metroplis algorithm pseudocode and code that runs with the givens in the picture satified thanks Problem 2.7 (a) How would you set up
Problem 2.7 (a) How would you set up a Metropolis algorithm to generate samples from a Pois- son distribution, t; = Ne ^/j! for j = 0,1,2,.... In particular, specify an appropriate transi- tion matrix Q and the acceptance probability a. Hint: The chain should have support on the non-negative integers and be simple to generate. In the Beta example, I used independent uniforms for the proposal. For this problem, consider using a simple random walk. (b) (extra-credit) Write a program to generate observations from a Poisson based on your pseudo- code and then run it. Display your program with details and include the results of a run
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
