Description Usage Arguments Details Value Author(s) See Also Examples
Elastic net uses a mixing parameter alpha
to tune the penalty term continuously from ridge (alpha=0
) to lasso (alpha=1
). eNetXplorer
generates a family of elastic net models over different values of alpha
for the quantitative exploration of the effects of shrinkage. For each alpha
, the regularization parameter lambda
is chosen by optimizing a quality function based on outofbag crossvalidation predictions. Statistical significance of each model, as well as that of individual features within a model,
is assigned by comparison to a set of null models generated by random permutations of the response. eNetXplorer
fits linear (gaussian), logistic (binomial) and multinomial models.
1 2 3 4 
x 
Input numerical matrix with instances as rows and features as columns. Instance and feature labels should be provided as row and column names, respectively. Can be in sparse matrix format (inherit from class 
y 
Response variable. For 
family 
Response type: 
alpha 
Sequence of values for the mixing parameter penalty term in the elastic net family. Default is 
nlambda 
Number of values for
the regularization parameter 
nlambda.ext 
If set to a value larger than 
seed 
Sets the pseudorandom number seed to enforce reproducibility. Default is 
scaled 
Zscore transformation of individual features across all instances. Default is 
n_fold 
Number of crossvalidation folds per run. 
n_run 
Number of runs; for each run, instances are randomly assigned to crossvalidation folds. Default is 100. 
n_perm_null 
Number of random nullmodel permutations of the response per run. Default is 25. 
QF.FUN 
Userdefined quality function as maximization criterion to select 
QF_label 
Label for userdefined quality function, if QF.FUN is provided. 
cor_method 
For 
fold_distrib_fail.max 
For categorical models, maximum number of failed attempts per run to have all classes represented in each inbag fold. If this number is exceeded, the execution is halted; try again with larger 
... 
Accepts parameters from 
For each alpha
, a set of nlambda
values is
obtained using the full data; if provided, nlambda.ext
allows to extend the range of lambda
values symmetrically while keeping its density uniform in log scale. Using these
values of lambda
, elastic net crossvalidation models are generated for n_run
random assignments of instances among n_fold
folds; the best lambda
is determined
by the maximization of a quality function that compares outofbag predictions against the response. Userdefined quality functions can be provided via QF.FUN
, otherwise sensible defaults are used (e.g. correlation for gaussian models).
For each run, using the same assignment of instances into folds, n_perm_null
null models are generated by shuffling the response. By using the quality function to compare the outofbag performance of the model to that of the null models,
an empirical significance pvalue is assigned to the model.
Similar procedures allow to obtain pvalues for individual features based on absolute coefficient magnitude and on the frequency of nonzero coefficients.
A family of elastic net models is thus generated for multiple
values of alpha
spanning the range from
ridge (alpha=0
) to lasso (alpha=1
). This function
returns an eNetXplorer
object on which summary, plotting
and export functions in this package can be applied for further
analysis.
For details about the underlying elastic net models, please refer to the glmnet
package and references therein.
An object with S3 class "eNetXplorer"
.
predictor 
Predictor matrix used for regression (in sparse matrix format). 
response 
Response variable used for regression. 
family 
Input parameter. 
alpha 
Input parameter. 
nlambda 
Input parameter. 
nlambda.ext 
Input parameter. 
seed 
Input parameter. 
scaled 
Input parameter. 
n_fold 
Input parameter. 
n_run 
Input parameter. 
n_perm_null 
Input parameter. 
QF_label 
Input parameter. 
cor_method 
Input parameter. 
fold_distrib_fail.max 
Input parameter. 
instance 
Instance labels. 
feature 
Feature labels. 
glmnet_params 

best_lambda 

model_QF_est 
Quality function values obtained by crossvalidation. 
QF_model_vs_null_pval 
Pvalue from model vs null comparison to assess statistical significance. 
lambda_values 
List of 
lambda_QF_est 
List of quality function values obtained for each 
predicted_values 
List of outofbag predicted values for each 
feature_coef_wmean 
Mean of feature coefficients (over runs) weighted by nonzero frequency (over folds) in sparse matrix format, with features as rows and 
feature_coef_wsd 
Standard deviation of feature coefficients (over runs) weighted by nonzero frequency (over folds) in sparse matrix format, with features as rows and 
feature_freq_mean 
Mean of nonzero frequency in sparse matrix format, with features as rows and 
feature_freq_sd 
Standard deviation of nonzero frequency in sparse matrix format, with features as rows and 
null_feature_coef_wmean 
Analogous to 
null_feature_coef_wsd 
Analogous to 
null_feature_freq_mean 
Analogous to 
null_feature_freq_sd 
Analogous to 
feature_coef_model_vs_null_pval 
Pvalue from model vs null comparison to assess statistical significance of mean nonzero feature coefficients in sparse matrix format, with features as rows and 
feature_freq_model_vs_null_pval 
Pvalue from model vs null comparison to assess statistical significance of mean nonzero feature frequencies in sparse matrix format, with features as rows and 
Julian Candia and John S. Tsang
Maintainer: Julian Candia [email protected]
summary
, plot
, summaryPDF
, export
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31  ## Not run:
# Linear models (synthetic dataset comprised of 20 features and 75 instances):
data(QuickStartEx)
fit = eNetXplorer(x=QuickStartEx$predictor, y=QuickStartEx$response,
family="gaussian", n_run=20, n_perm_null=10, seed=111)
# Linear models to predict numerical day70 H1N1 serum titers based on
day7 cell population frequencies:
data(H1N1_Flow)
fit = eNetXplorer(x=H1N1_Flow$predictor_day7, y=H1N1_Flow$response_numer[rownames(
H1N1_Flow$predictor_day7)], family="gaussian", n_run=25, n_perm_null=15, seed=111)
# Binomial models to predict acute myeloid (AML) vs acute lymphoblastic (ALL)
#leukemias:
data(Leukemia_miR)
fit = eNetXplorer(x=Leukemia_miR$predictor, y=Leukemia_miR$response_binomial,
family="binomial", n_run=25, n_perm_null=15, seed=111)
# Multinomial models to predict acute myeloid (AML), acute Bcell lymphoblastic
# (BALL) and acute Tcell lymphoblastic (TALL) leukemias:
data(Leukemia_miR)
fit = eNetXplorer(x=Leukemia_miR$predictor, y=Leukemia_miR$response_multinomial,
family="multinomial", n_run=25, n_perm_null=15, seed=111)
# Binomial models to predict BALL vs TALL:
data(Leukemia_miR)
fit = eNetXplorer(x=Leukemia_miR$predictor[Leukemia_miR$response_multinomial!="AML",],
y=Leukemia_miR$response_multinomial[Leukemia_miR$response_multinomial!="AML"],
family="binomial", n_run=25, n_perm_null=15, seed=111)
## End(Not run)

Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.