Learn R Programming

plotMCMC (version 2.0.1)

plotCumu: Plot MCMC Cumulative Quantiles

Description

Plot Markov chain Monte Carlo cumulative quantiles. This is a diagnostic plot for deciding whether the chain has converged.

Usage

plotCumu(mcmc, probs=c(0.025,0.975), div=1, log=FALSE, base=10,
         main=NULL, xlab="Iterations", ylab="Value", lty.median=1,
         lwd.median=2, col.median="black", lty.outer=2, lwd.outer=1,
         col.outer="black", …)

Arguments

mcmc

MCMC chain(s) as a vector, data frame or mcmc object.

probs

vector of outer quantiles to draw, besides the median.

div

denominator to shorten values on the y axis.

log

whether values should be log-transformed.

base

logarithm base.

main

main title.

xlab

x-axis label.

ylab

y-axis label.

lty.median

line type of median.

lwd.median

line width of median.

col.median

color of median.

lty.outer

line type of outer quantiles.

lwd.outer

line width of outer quantiles.

col.outer

color of outer quantiles.

passed to cumuplot, title, and axis.

Value

Null, but a plot is drawn on the current graphics device.

See Also

cumuplot is the underlying plotting function, and quantile is called iteratively to calculate the cumulative quantiles.

plotTrace, plotAuto, plotCumu, and plotSplom are diagnostic plots.

plotDens and plotQuant are posterior plots.

plotMCMC-package gives an overview of the package.

Examples

Run this code
# NOT RUN {
plotCumu(xpar$R0, main="R0")
plotCumu(xpar$cSfull, main="cSfull")
plotCumu(xpar, probs=c(0.25,0.75), ann=FALSE, axes=FALSE)
# }

Run the code above in your browser using DataLab