Learn R Programming

lsgl (version 1.3.5)

lambda: Compute a lambda sequence for the regularization path

Description

Computes a decreasing lambda sequence of length d. The sequence ranges from a data determined maximal lambda $\lambda_\textrm{max}$ to the user inputed lambda.min.

Usage

lambda(x, y, intercept = TRUE, weights = NULL, grouping = NULL, groupWeights = NULL, parameterWeights = NULL, alpha = 1, d = 100L, lambda.min, lambda.min.rel = FALSE, algorithm.config = lsgl.standard.config)

Arguments

x
design matrix, matrix of size $N \times p$.
y
response matrix, matrix of size $N \times K$.
intercept
should the model include intercept parameters.
weights
sample weights, vector of size $N \times K$.
grouping
grouping of features, a factor or vector of length $p$. Each element of the factor/vector specifying the group of the feature.
groupWeights
the group weights, a vector of length $m$ (the number of groups).
parameterWeights
a matrix of size $K \times p$.
alpha
the $\alpha$ value 0 for group lasso, 1 for lasso, between 0 and 1 gives a sparse group lasso penalty.
d
the length of lambda sequence
lambda.min
the smallest lambda value in the computed sequence.
lambda.min.rel
is lambda.min relative to lambda.max ? (i.e. actual lambda min used is lambda.min*lambda.max, with lambda.max the computed maximal lambda value)
algorithm.config
the algorithm configuration to be used.

Value

a vector of length d containing the compute lambda sequence.