predict.Model {glmmrBase}R Documentation

Generate predictions at new values from a 'Model' object

Description

Generates predicted values from a 'Model' object using a new data set to specify covariance values and values for the variables that define the covariance function. The function will return a list with the linear predictor, conditional distribution of the new random effects term conditional on the current estimates of the random effects, and some simulated values of the random effects if requested. Typically this functionality is accessed using 'Model$predict()', which this function provides a wrapper for.

Usage

## S3 method for class 'Model'
predict(object, newdata, offset = rep(0, nrow(newdata)), m = 0, ...)

Arguments

object

A 'Model' object.

newdata

A data frame specifying the new data at which to generate predictions

offset

Optional vector of offset values for the new data

m

Number of samples of the random effects to draw

...

Further arguments passed from other methods

Value

A list with the linear predictor, parameters (mean and covariance matrices) for the conditional distribution of the random effects, and any random effect samples.


[Package glmmrBase version 0.9.2 Index]