Description Usage Arguments Value Author(s) See Also Examples
Creates a trace plot for one parameter in an MCMC simulation. This function is called by the mcmcplot
function, and is intended for internal use only.
1 |
x |
an |
col |
one or more colors for the trace lines. Default is |
lty |
one or more line types for the trace lines. |
style |
if "gray", then the plotting region is printed with a gray background, otherwise the default plotting region is used. |
... |
further arguments passed to the plotting function. |
Creates a plot.
S. McKay Curtis
mcmcplot1
, denoverplot1
, autplot1
1 2 3 4 5 6 7 8 9 10 11 | ## Create fake MCMC output
nc <- 10; nr <- 1000
pnames <- c(paste("alpha[", 1:5, "]", sep=""), paste("gamma[", 1:5, "]", sep=""))
means <- rpois(10, 20)
fakemcmc <- coda::as.mcmc.list(
lapply(1:3,
function(i) coda::mcmc(matrix(rnorm(nc*nr, rep(means,each=nr)),
nrow=nr, dimnames=list(NULL,pnames)))))
traplot(fakemcmc[, "alpha[5]", drop=FALSE])
traplot(fakemcmc[, "alpha[5]", drop=FALSE], style="plain")
|
Loading required package: coda
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.