Plotting methods for objects of class "bamlss" and "bamlss.results", which can be used for producing effect plots of model terms, trace plots of samples or residual plots. Note that effect plots of model terms with more than two covariates are not supported, for this purpose use function predict.bamlss.

# S3 method for bamlss
plot(x, model = NULL, term = NULL,
which = "effects", parameters = FALSE,
ask = dev.interactive(), spar = TRUE, ...)

# S3 method for bamlss.results
plot(x, model = NULL, term = NULL,
ask = dev.interactive(), scale = 1, spar = TRUE, ...)

## Arguments

x An object of class "bamlss" or "bamlss.results". Character or integer. For which model should the plots be created? Character or integer. For which model term should a plot be created? Character or integer, selects the type of plot: "effects" produces effect plots of smooth model terms, "samples" shows trace plots of samples, "hist-resid" shows a histogram of residuals (see also residuals.bamlss for the different available types), "qq-resid" shows a quantile-quantile plot of residuals, "scatter-resid" shows a scatter plot of residuals with fitted values for the distribution mean (if available in the family object), "max-acf" shows an acf plot of the maximum autocorrelation of all parameter samples. For trace plots of parameters, should corresponding parameter values as returned from an optimizer function (e.g., bfit) be added as horizontal lines? For multiple plots, the user is asked to show the next plot. If set to 1, effect plots all have the same scale on the y-axis. If set to 0 each effect plot has its own scale for the y-axis. Should graphical parameters be set? Arguments to be passed to plot2d, plot3d, sliceplot, plotblock, plotmap and residuals.bamlss.

bamlss, results.bamlss.default, residuals.bamlss.

## Examples

# NOT RUN {
## Generate some data.
d <- GAMart()

## Model formula.
f <- list(
num ~ s(x1) + s(x2) + s(x3) + te(lon,lat),
sigma ~ s(x2) + te(lon,lat)
)

## Estimate model.
b <- bamlss(f, data = d)

## Effect plots
# }