like lasso and ridge, elastic net can also be used for classification by using the deviance instead of the residual sum of squares. This essentially happens automatically in caret if the response variable is a factor.
This is from topepo caret github. However, although I searched the internet. No one one really seems to tell what 'glmnet' really is ? For example, if I do the following, for a binary classication task.
glm_net = train( y ~ . , data = train_set, method = 'glmnet', trControl = fitControl, metric = 'ROC')
What is it really? A logistic regression? And it also come with lasso and ridge regression regularization, but it cant be linear regression because it is classification..