View source: R/trans_feature_selection_fss.R
| feature_selection_fss | R Documentation |
Selects numeric predictors using forward stepwise subset search.
feature_selection_fss(attribute, features = NULL)
attribute |
target attribute name |
features |
optional vector of feature names (default: all columns except |
Adds one predictor at a time (greedy forward selection) and keeps the subset with the highest adjusted R-squared, which penalizes adding predictors that do not pay for their complexity. The target attribute must be numeric.
Implemented with base stats::lm (see references for the method).
returns an object of class feature_selection_fss
Hocking, R. R. (1976). The Analysis and Selection of Variables in Linear Regression. Biometrics, 32(1):1-49. Miller, A. (2002). Subset Selection in Regression (2nd ed.). Chapman & Hall/CRC.
data(mtcars)
fs <- feature_selection_fss("mpg")
fs <- fit(fs, mtcars)
fs$selected
mtcars_fs <- transform(fs, mtcars)
names(mtcars_fs)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.