Plot Traces of Specified Parameters from a Fitted Stan Model
plot_traces.Rd
Generates trace plots for specified parameters from a fitted Stan model contained within a bipod
object. The plots visualize the sampled values across iterations for each chain.
Usage
plot_traces(x, fit, pars = c(), diagnose = FALSE)
Arguments
- x
A
bipod
object that contains at least one fitted model.- fit
The fit within the
bipod
object for which the traces should be plotted.- pars
A character vector specifying the names of the parameters to plot. If empty, plots all available parameters.
- diagnose
A logical value indicating whether to color the plots based on convergence diagnostics. If
TRUE
, the plots will include color coding based on the R-hat convergence statistic. (default is FALSE)