mcmc_plot.mvgam {mvgam} | R Documentation |
MCMC plots as implemented in bayesplot
Description
Convenient way to call MCMC plotting functions implemented in the bayesplot package
Usage
## S3 method for class 'mvgam'
mcmc_plot(
object,
type = "intervals",
variable = NULL,
regex = FALSE,
use_alias = TRUE,
...
)
Arguments
object |
An R object typically of class |
type |
The type of the plot.
Supported types are (as names) |
variable |
Names of the variables (parameters) to plot, as given by a
character vector or a regular expression (if |
regex |
Logical; Indicates whether |
use_alias |
Logical. If more informative names for parameters are available
(i.e. for beta coefficients |
... |
Additional arguments passed to the plotting functions.
See |
Value
A ggplot
object
that can be further customized using the ggplot2 package.
See Also
mvgam_draws
for an overview of some of the shortcut strings
that can be used for argument variable
Examples
## Not run:
simdat <- sim_mvgam(n_series = 1, trend_model = AR())
mod <- mvgam(y ~ s(season, bs = 'cc', k = 6),
trend_model = AR(),
noncentred = TRUE,
data = simdat$data_train,
chains = 2)
mcmc_plot(mod)
mcmc_plot(mod, type = 'neff_hist')
mcmc_plot(mod, variable = 'betas', type = 'areas')
mcmc_plot(mod, variable = 'trend_params', type = 'combo')
## End(Not run)