Closed youngahn closed 7 years ago
The current implementation should allow for any arguments to glmnet (or random forest or support vector machines for that matter) to be passed through, in both Python and R.
For example, the below code should work in R without any problem:
library(easyml) # https://github.com/CCS-Lab/easyml
# Load data
data("cocaine_dependence", package = "easyml")
# Analyze data
results <- easy_glmnet(cocaine_dependence, "diagnosis",
family = "binomial", exclude_variables = c("subject"),
categorical_variables = c("male"), preprocessor = preprocess_scaler,
n_samples = 100, n_divisions = 100, n_iterations = 10,
random_state = 1, n_core = 8, alpha = 1)
Was there a specific behavior you noticed that didn't work properly or was this just a generic request?
Okay great. It wasn't clear any arguments to glmnet can be passed through. Later please make a note in Description.
But I think it's a good idea to leave 'alpha' as an input argument in easy_glmnet. It's an important tuning parameter of glmnet and users need to know its existence.
alpha (between 0 (ridge) and 1 (lasso)) should be an input.
See ?glmnet::glmnet and 'alpha' (default = 1).