glmpath(x, y, data, nopenalty.subset = NULL, family = binomial, weight = rep(1, n), offset = rep(0, n), lambda2 = 1e-5, max.steps = 10*min(n, m), max.norm = 100*m, min.lambda = (if (m >= n) 1e-6 else 0), max.vars = Inf, max.arclength = Inf, frac.arclength = 1, add.newvars = 1, bshoot.threshold = 0.1, relax.lambda = 1e-8, standardize = TRUE, function.precision = 3e-13, eps = .Machine$double.eps, trace = FALSE)x: a matrix of features and y:
response. data is not needed if x and y are
input separately.
binomial, gaussian,
or poisson. For each one, the canonical link function is
used; logit for binomial, identity for gaussian, and
log for poisson distribution. Default is binomial.
x is used as
offset, the corresponding column must be removed from x.
1e-5.
10 * min{nrow(x), ncol(x)}.
100 * ncol(x).
0 for ncol(x) < nrow(x) cases and 1e-6
otherwise.
Inf.
max.arclength is extremely small, an exact nonlinear path is
produced. Default is Inf.
frac.arclength is assigned some fraction between 0 and 1, the
step size is decreased by the factor of frac.arclength in arc
length. If frac.arclength=0.2, the step length is adjusted so
that the active set would change after five smaller steps. Either
max.arclength or frac.arclength can be used to force
the path to be more accurate. Default is 1.
add.newvars candidate variables (that are currently not in
the active set) are used in the corrector step as potential active
variables. Default is 1.
bshoot.threshold at the first corrector step it becomes
nonzero (therefore when $\lambda$ is considered to have been
decreased too far), $\lambda$ is increased again. i.e. A
backward distance in $\lambda$ that makes the coefficient zero
is computed. Default is 0.1.
relax.lambda). Default is 1e-8. If no
variable joins the active set even after many (>20) steps, the user
should increase relax.lambda to 1e-7 or 1e-6,
but not more than that. This adjustment is sometimes needed because
of the numerical precision/error propagation problems. In general,
the paths are less accurate with relaxed lambda.
TRUE, predictors are standardized to have a unit variance.
function.precision parameter used in the internal
solver. Default is 3e-13. The algorithm is faster, but less
accurate with relaxed, larger function precision.
TRUE, the algorithm prints out its progress.
glmpath object is returned.
TRUE if the predictors were standardized before fitting
We thank Michael Saunders of SOL, Stanford University for providing the solver used for the convex optimization in corrector steps of glmpath.