plot_trace: Plot traces of posterior draws of a parameter

Description Usage Arguments Value See Also

View source: R/plot_trace.r

Description

Plots the posterior draws of a specified parameter by MCMC iteration with options for visual differentiation of separate chains.

Usage

1
2
plot_trace(postob, vname, pscale = "original", stack = FALSE,
  colset = "color")

Arguments

postob

An array containing posterior draws from a spmrf model fit or stan model fit. Model fit objects of type stanfit can be coerced into arrays using either the extract or as.array.stanfit functions from the rstan package.

vname

Name of variable to plot. Name must correspond to a dimname in the array.

pscale

Plotting scale. Options are 'original', 'log', or 'inv' (inverse).

stack

Indicator to plot chains separately and stack the plots.

colset

Color scheme for plotting traces by chain. Schemes 'color' and 'gray' will produce separate colors or gray shades for each chain, and scheme 'black' will make all chain traces black.

Value

Returns a plot object

See Also

stanfit, extract, as.array.stanfit, spmrf


jrfaulkner/spmrf documentation built on Sept. 27, 2020, 12:34 p.m.