\name{lasso.path.isolambda_descent} \alias{lasso.path.isolambda_descent} \title{computation of the LASSO path} \description{ Computes the LASSO regularization path by steps by the iso-lambda descent method. } \usage{ lasso.path.isolambda_descent(x, y, penalizations = NULL, min.lambda.ratio = 0.05, steps="auto") } \arguments{ \item{x}{ the design matrix. Rows are observations, lines are features. Must be stored by column (default in R). } \item{y}{ the response vector. } \item{penalizations}{ individual penalizations of features, or NULL. Must be nonnegative. } \item{min.lambda.ratio}{ the lowest value of the regularization parameter, as a ratio over the greatest one (between 0 and 1). Used only with \code{path="auto"}. } \item{steps}{ the values of the penalization parameter, as ratios over the greatest value (between 0 and 1). automatically reordered in descending direction. } } \details{} \value{ list of records for each step. Each item contains \item{lambda}{the regularization parameter} \item{t}{the corresponding L1 constraint, ie the L1 norm of the coefficient} \item{num_active}{the number of active features} \item{indices}{the indices of active features} \item{beta}{the coefficients of active features in the regularized solution} \item{beta.PLS}{the coefficients of active features in the partial least-square solution (least square on active features)} \item{hsr}{half squared residual: 0.5 * |y-x'beta|^2, for the regularized solution} \item{hsr.PLS}{half squared residual: 0.5 * |y-x'beta|^2, for the partial least-square solution} } \references{ } \author{ Manuel Loth } \note{ } \seealso{ \code{lasso.path.homotopy} \code{lasso.path-package} } \examples{ ##---- Should be DIRECTLY executable !! ---- ##-- ==> Define data, use random, ##-- or do help(data=index) for the standard data sets. ## The function is currently defined as function (x, y, penalizations = NULL, min.lambda.ratio = 0.05, steps = "auto") { nsteps <- min(dim(x)) if (dim(x)[2] != length(y)) return x <- as.double(x) y <- as.double(y) if (!is.null(penalizations)) penalizations <- as.double(penalizations) if (steps == "auto") { steps <- exp(seq(log(1), log(min.lambda.ratio), length.out = nsteps)) steps <- steps[steps >= min.lambda.ratio] } else { if (max(steps) > 1 || min(steps) < 0) return steps <- sort(steps, decreasing = T) steps[steps == 0] <- 1e-05 } r <- .Call("lasso_path_isolambda_descent_R", x, y, penalizations, steps) return(r) } }