predict.uplift_glm: Predict method for uplift_glm fits.

View source: R/uplift_glm.R

predict.uplift_glmR Documentation

Predict method for uplift_glm fits.

Description

Obtains predictions from a fitted uplift_glm object.

Usage

## S3 method for class 'uplift_glm'
predict(object, newdata = NULL, type = "uplift",
  na.action = na.omit, ...)

Arguments

object

A fitted object inheriting from uplift_glm.

newdata

An optional set of data to predict on. If NULL, then the original data are used.

type

The type of predictions required. Only "uplift" predictions are allowed.

na.action

The method for handling missing data.

...

Additional arguments to be passed to other methods.

Value

A numeric vector of predictions for all methods, except when the model was fitted using method = "glmnet", in which case the returned object is a matrix of predictions for the entire sequence of the penalty parameter used to create the model.

Author(s)

Leo Guelman leo.guelman@gmail.com

See Also

uplift_glm


leoguelman/uplift2 documentation built on April 15, 2022, 4:34 a.m.