COPY_biglasso_main | R Documentation |
Fit solution paths for linear or logistic regression models penalized by lasso (alpha = 1) or elastic-net (1e-4 < alpha < 1) over a grid of values for the regularization parameter lambda.
COPY_biglasso_main(
X,
y.train,
ind.train,
ind.col,
covar.train,
family = c("gaussian", "binomial"),
alphas = 1,
K = 10,
ind.sets = NULL,
nlambda = 200,
lambda.min.ratio = if (n > p) 1e-04 else 0.001,
nlam.min = 50,
n.abort = 10,
base.train = NULL,
pf.X = NULL,
pf.covar = NULL,
eps = 1e-05,
max.iter = 1000,
dfmax = 50000,
lambda.min = if (n > p) 1e-04 else 0.001,
power_scale = 1,
power_adaptive = 0,
return.all = FALSE,
warn = TRUE,
ncores = 1
)
family |
Either "gaussian" (linear) or "binomial" (logistic). |
alphas |
The elastic-net mixing parameter that controls the relative contribution from the lasso (l1) and the ridge (l2) penalty. The penalty is defined as
|
K |
Number of sets used in the Cross-Model Selection and Averaging
(CMSA) procedure. Default is |
ind.sets |
Integer vectors of values between |
nlambda |
The number of lambda values. Default is |
lambda.min.ratio |
The smallest value for lambda, as a fraction of
lambda.max. Default is |
nlam.min |
Minimum number of lambda values to investigate. Default is |
n.abort |
Number of lambda values for which prediction on the validation
set must decrease before stopping. Default is |
base.train |
Vector of base predictions. Model will be learned starting from these predictions. This can be useful if you want to previously fit a model with large-effect variables that you don't want to penalize. |
pf.X |
A multiplicative factor for the penalty applied to each coefficient.
If supplied, |
pf.covar |
Same as |
eps |
Convergence threshold for inner coordinate descent.
The algorithm iterates until the maximum change in the objective after any
coefficient update is less than |
max.iter |
Maximum number of iterations. Default is |
dfmax |
Upper bound for the number of nonzero coefficients. Default is
|
lambda.min |
This parameter has been renamed |
power_scale |
When using lasso (alpha = 1), penalization to apply that
is equivalent to scaling genotypes dividing by (standard deviation)^power_scale.
Default is 1 and corresponding to standard scaling. Using 0 would correspond
to using unscaled variables and using 0.5 is Pareto scaling. If you e.g. use
|
power_adaptive |
Multiplicative penalty factor to apply to variables
in the form of 1 / m_j^power_adaptive, where m_j is the marginal statistic
for variable j. Default is 0, which effectively disables this option.
If you e.g. use |
return.all |
Deprecated. Now always return all models. |
warn |
Whether to warn if some models may not have reached a minimum.
Default is |
The objective function for linear regression (family = "gaussian"
) is
\frac{1}{2n}\textrm{RSS} + \textrm{penalty},
for logistic regression
(family = "binomial"
) it is
-\frac{1}{n} loglike +
\textrm{penalty}.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.