Hello, dear friend, you can consult us at any time if you have any questions, add WeChat: daixieit

Tutorial 11 Problem Set

The zero-inflated Poisson model is defined as follows:

p ~ U (0, 1)

λlp ~ Γ(a, b)

rilp, λ ~ Ber(p)

xilr, λ ~ Pois(λri)

where a, b are known.

1.  Simulate drawing 1000 integers y = (y1 , . . . , y1000 ) from a zero-inflated Poisson data model with p = 0.1 and λ = 10.  (You should already have code to do this from Q3a of the Tutorial 7 Problem Set.)

2. Let k(y) be the number of zeroes in your data set and let S(y) =      yi . Show that k and S are sufficient

for θ = (p, λ).

3. Write code to implement ABC and use it to draw 100 values of θ from the approximate posterior distribution pe(θly), where e = 10. Plot marginal distributions for p and λ .

4. Improve the estimates of θ obtained in Question 3 using regression adjustment, and again plot marginal distributions for p and λ .

5.  Repeat Question 3 with MCMC ABC.

6.  Repeat Question 3 with SMC ABC.