LARSModel | R Documentation |
Fit variants of Lasso, and provide the entire sequence of coefficients and fits, starting from zero to the least squares fit.
LARSModel(
type = c("lasso", "lar", "forward.stagewise", "stepwise"),
trace = FALSE,
normalize = TRUE,
intercept = TRUE,
step = numeric(),
use.Gram = TRUE
)
type |
model type. |
trace |
logical indicating whether status information is printed during the fitting process. |
normalize |
whether to standardize each variable to have unit L2 norm. |
intercept |
whether to include an intercept in the model. |
step |
algorithm step number to use for prediction. May be a decimal
number indicating a fractional distance between steps. If specified, the
maximum number of algorithm steps will be |
use.Gram |
whether to precompute the Gram matrix. |
numeric
step
Default argument values and further model details can be found in the source See Also link below.
MLModel
class object.
lars
, fit
, resample
## Requires prior installation of suggested package lars to run
fit(sale_amount ~ ., data = ICHomes, model = LARSModel)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.