preferable: Preferable Elastic Net Model

Description Usage Arguments Value

View source: R/ensr.R

Description

Find the preferable Elastic Net Model from an ensr object. The preferable model is defined as the model with the lowest mean cross validation error and largest alpha value.

Usage

1
preferable(object, ...)

Arguments

object

an ensr object

...

not currently used.

Value

a glmnet object associated with the smallest cvm. If the min cvm is not unique, then the model with the smallest cvm with largest alpha value is returned. If that is not unique, then is all the "preferable" models have zero non-zero coefficients the model with the largest lambda and largest alpha value is returned. Lastly, if a unquie model is still not identified an error will be thrown.


dewittpe/ensr documentation built on March 6, 2020, 5:24 p.m.