MCMCdynamicEI(r0, r1, c0, c1, burnin=5000, mcmc=200000, thin=200,
tune=2.65316, verbose=FALSE, seed=0, W=0, nu0=1,
delta0=0.5, nu1=1, delta1=0.5, ...)
mcmc
object that contains the posterior density sample.
This object can be summarized by functions provided by the coda package.The following prior distributions are assumed: $$p(\theta_0|\sigma^2_0) \propto \sigma_0^{-ntables} \exp \left(-\frac{1}{2\sigma^2_0} \theta'_{0} P \theta_{0}\right)$$ and $$p(\theta_1|\sigma^2_1) \propto \sigma_1^{-ntables} \exp \left(-\frac{1}{2\sigma^2_1} \theta'_{1} P \theta_{1}\right)$$ where $P_{ts}$ = $-W_{ts}$ for $t$ not equal to $s$ and $P_{tt}$ = $\sum_{s \ne t}W_{ts}$. The $\theta_{0t}$ is assumed to be a priori independent of $\theta_{1t}$ for all t. In addition, the following hyperpriors are assumed: $\sigma^2_0 \sim \mathcal{IG}(\nu_0/2, \delta_0/2)$, and $\sigma^2_1 \sim \mathcal{IG}(\nu_1/2, \delta_1/2)$.
Inference centers on $p_0$, $p_1$, $\sigma^2_0$, and $\sigma^2_1$. The Metropolis-Hastings algorithm is used to sample from the posterior density.
Kevin M. Quinn. 2002. ``Ecological Inference in the Presence of Temporal Dependence." Paper prepared for Ecological Inference Conference, Harvard University, June 17-18, 2002.
Andrew D. Martin, Kevin M. Quinn, and Daniel Pemstein. 2002. Scythe Statistical
Library 0.3.
MCMCbaselineEI
, MCMChierEI
,
plot.mcmc
,summary.mcmc
r0 <- rpois(10, 300)
r1 <- rpois(10, 200)
c0 <- 100 + 1:10*7 + rpois(10, 30)
c1 <- (r0+r1) - c0
posterior <- MCMCdynamicEI(r0, r1, c0, c1, verbose=TRUE,
burnin=10000, mcmc=5000000, thin=1000)
Run the code above in your browser using DataLab