Skip to contents

Produces predictions from a glmsusie model for new data or the original training data.

Usage

# S3 method for class 'glmsusie'
predict(object, newdata = NULL, type = c("link", "response", "terms"), ...)

Arguments

object

A fitted model object of class "glmsusie".

newdata

An optional data frame or matrix in which to look for variables with which to predict. If omitted, the fitted values are returned.

type

Character string specifying the type of prediction:

  • "link": predictions on the scale of the linear predictors

  • "response": predictions on the scale of the response

  • "terms": the contributions of individual terms

...

Additional arguments passed to the family's link function.

Value

Vector or matrix of predictions, depending on the type.