Automatically calculate and apply burnin value

autoburnin(jags_out, return.burnin = FALSE, ...)

Arguments

jags_out

List of MCMC sample matrices or `mcmc.list` object

return.burnin

Logical. If `TRUE`, return burnin value in addition to samples (as list). Default = FALSE.

...

Additional arguments for getBurnin, gelman_diag_mw, and gelman.diag.

Examples

# NOT RUN {
     z1 <- coda::mcmc(c(rnorm(2500, 5), rnorm(2500, 0)))
     z2 <- coda::mcmc(c(rnorm(2500, -5), rnorm(2500, 0)))
     z <- coda::mcmc.list(z1, z2)
     z_burned <- autoburnin(z)
# }