results.bamlss.default: Compute BAMLSS Results for Plotting and Summaries

results.bamlss.defaultR Documentation

Compute BAMLSS Results for Plotting and Summaries

Description

The results function combines estimated parameters and/or samples with the bamlss.frame and computes the data that can be used, e.g., for creating effect plots or summary statistics. The function is usually used internally within bamlss. The object returned is of class "bamlss.results", which has a plotting method, see plot.bamlss.results.

Usage

results.bamlss.default(x, what = c("samples", "parameters"),
  grid = -1, nsamps = NULL, burnin = NULL, thin = NULL, ...)

Arguments

x

A bamlss.frame which has estimated parameters or samples. See also bfit and GMCMC.

what

Should the results data be prepared using estimated parameters or samples?

grid

Integer, sets the number of grid points for univariate functions to be used for creating results data, e.g., for plotting. This is more efficient when using data sets with a large number of unique covariate values. If negative suitable defaults are chosen.

nsamps

Integer, if results are computed using parameter samples, this argument controls the number of samples that should be used, e.g., if nsamps = 100 only 100 samples with equidistant intervals are selected. Basically similar to argument thin.

burnin

Integer, sets the number of samples that should be dropped from the beginning of the MCMC chain when creating results.

thin

Integer, should the MCMC chain be thinned additionally?

...

Currently not used.

Value

An object of class "bamlss.results".

See Also

plot.bamlss.results, bamlss.

Examples

## Not run: ## Simulate data.
d <- GAMart()

## Estimate model with no results.
b <- bamlss(num ~ s(x1) + s(x2) + s(x3),
  data = d, results = FALSE)

## Compute model results
a <- results.bamlss.default(b)

## Plot results for smooth terms.
plot(a)

## End(Not run)

bamlss documentation built on Oct. 11, 2024, 5:07 p.m.