traceplot: Traceplot for Bayesian Model Sampling

View source: R/plots.R

traceplotR Documentation

Traceplot for Bayesian Model Sampling

Description

The traceplot function is a generic function used to generate traceplots for Bayesian model sampling, primarily for assessing the convergence and mixing of Markov Chain Monte Carlo (MCMC) chains. This function dispatches specific traceplot methods depending on the class of the object object.

Usage

traceplot(object, ...)

Arguments

object

An object representing a Bayesian model, typically generated by the cat_glm_bayes or cat_cox_bayes functions, or similar models with Bayesian sampling results. The function uses S3 method dispatch to apply the appropriate traceplot method based on the class of object.

...

Additional arguments passed to specific traceplot methods for customization, such as selecting parameters to plot or setting display options.

Details

This generic traceplot function allows for flexible visualization of MCMC chains across different types of Bayesian models. Specific traceplot methods, such as traceplot.cat_bayes, are dispatched based on the object class to produce tailored traceplots, providing insights into the sampling progress and convergence diagnostics of each chain.

Value

A traceplot displaying the MCMC sampling chains for each parameter, assisting in convergence analysis. The exact output format depends on the specific traceplot method applied.


catalytic documentation built on April 4, 2025, 5:51 a.m.