bayes_trace {BayesMultiMode}R Documentation

Trace plots

Description

This is wrapper around the bayesplot::mcmc_trace() function from package bayesplot.

Usage

bayes_trace(BayesMix, mcmc_vars = NULL, with_burnin = FALSE, ...)

Arguments

BayesMix

An object of class bayes_mixture.

mcmc_vars

Variables to plot; default is all the variable in the MCMC output.

with_burnin

Plot all draws ?

...

Additional arguments passed to function bayesplot::mcmc_trace().

Value

A trace plot.

Examples

# Example with galaxy data ================================================
set.seed(123) 

# retrieve galaxy data
y = galaxy

# estimation
bayesmix = bayes_fit(data = y,
                           K = 5, #not many to run the example rapidly
                           dist = "normal",
                           nb_iter = 500, #not many to run the example rapidly
                           burnin = 100)

# trace plot
# bayes_trace(bayesmix)


[Package BayesMultiMode version 0.7.1 Index]