Tune the regularization parameter lambda for a sup-norm classifier by cross-validation.
Arguments
- x
A numeric matrix representing the design matrix. No missing valus are allowed. The coefficient estimates for constant columns will be zero. Thus, one should set the argument
intercept
toTRUE
to include an intercept term instead of adding an all-one column tox
.- y
An integer vector, a character vector, or a factor vector representing the response label.
- model
A charactor vector specifying the classification model. The available options are
"logistic"
for multi-nomial logistic regression model,"psvm"
for proximal support vector machine (PSVM),"svm"
for multi-category support vector machine.- penalty
A charactor vector specifying the penalty function for the sup-norms. The available options are
"lasso"
for sup-norm regularization proposed by Zhang et al. (2008) and"scad"
for supSCAD regularization proposed by Li & Zhang (2021).- start
A numeric matrix representing the starting values for the quadratic approximation procedure behind the scene.
- control
A list with named elements.
- nfolds
A positive integer specifying the number of folds for cross-validation. Five-folds cross-validation will be used by default. An error will be thrown out if the
nfolds
is specified to be less than 2.- stratified
A logical value indicating if the cross-validation procedure should be stratified by the response label. The default value is
TRUE
to ensure the same number of categories be used in validation and training.- ...
Other arguments passed to
supclass
.