traceplot.cat_gibbs {catalytic} | R Documentation |
Traceplot for Gibbs Sampling Model
Description
This function generates a traceplot for the Gibbs sampling model, which is typically used for posterior sampling in a Bayesian context. The traceplot visualizes the evolution of parameter values across Gibbs sampling iterations. It helps to diagnose the convergence and mixing of the chains.
Usage
## S3 method for class 'cat_gibbs'
traceplot(object, pars = NULL, inc_warmup = FALSE, ...)
Arguments
object |
A fitted model object of class |
pars |
A character vector specifying the parameter names to plot.
If |
inc_warmup |
A logical value indicating whether to include warmup iterations
in the traceplot. If |
... |
Additional parameters to pass to other functions. |
Details
The function generates a series of line plots for the selected parameters,
displaying their values over the iterations of the Gibbs sampling process.
If inc_warmup
is set to TRUE
, the traceplot includes the warmup period,
otherwise, it starts after the warmup. The traceplots are arranged in a 3x3 grid,
and no more than 9 parameters can be selected for plotting at once.
Value
A series of traceplots for the selected parameters, showing their evolution over the Gibbs sampling iterations.