Learn R Programming

ModelGood (version 1.0.9)

AutoSelectLRM: Automated backward elemination for logistic regression

Description

Wrapper for automated backward elemination for logistic regression

Usage

AutoSelectLRM(formula, data, ...)

Arguments

formula
passed to lrm
data
passed to lrm
...
passed to fastbw

Value

object of class AutoSelectLRM

Details

First run backward elemination via fastbw from the rms package, then fit the logistic regression model including the selected variables

See Also

fastbw lrm

Examples

Run this code
library(rms)
set.seed(7)
x <- abs(rnorm(20))
d <- data.frame(y=rbinom(20,1,x/max(x)),x=x,z=rnorm(20))
fbw <- AutoSelectLRM(y~x+z,d)
predictStatusProb(fbw,newdata=d[1:3,])

Run the code above in your browser using DataLab