SL.glm.gammaid: Generalized linear model with gamma family and identity link...

Description Usage Arguments Value Examples

View source: R/SL.glm.gamma.R

Description

See SL.glm.gamma.

Usage

1
SL.glm.gammaid(..., link = "identity")

Arguments

...

Other arguments passed to SL.glm.gamma.

link

Link function

Value

pred

Predicted outcomes based on predictors in newX

fit

A list with named entries object (the fitted glm regression object)

Examples

1
2
3
4
5
6
7
# load cost data
data(cost_data)
# fit gamma glm with identity link
fit_glm.gammaid <- SL.glm.gammaid(Y = cost_data$totalcost, X = cost_data[, c("female", "race")],
                              newX = cost_data[, c("female", "race")])
# get back predictions
pred_glm.gammaid <- predict(fit_glm.gammaid$fit, newdata = cost_data[,c("female", "race")])

wuziyueemory/twostageSL documentation built on Oct. 19, 2020, 3:45 p.m.