polynomialLogRegrFw {givitiR} | R Documentation |
Forward Selection in Polynomial Logistic Regression
Description
polynomialLogRegrFw
implements a forward selection in a
polynomial logistic regression model.
Usage
polynomialLogRegrFw(data, thres, maxDeg, startDeg)
Arguments
data |
A |
thres |
A numeric scalar between 0 and 1 representing the significance level adopted in the forward selection. |
maxDeg |
The maximum degree considered in the forward selection. |
startDeg |
The starting degree in the forward selection. |
Value
A list containing the following components:
- fit
An object of class
glm
containig the output of the fit of the logistic regression model at the end of the iterative forward selection.- m
The degree of the polynomial at the end of the forward selection.
Examples
e <- runif(100)
logite <- logit(e)
o <- rbinom(100, size = 1, prob = e)
data <- data.frame(e = e, o = o, logite = logite)
polynomialLogRegrFw(data, .95, 4, 1)