Learn R Programming

HTLR (version 0.4-4)

lasso_deltas: Lasso Initial State

Description

Generate initial Markov chain state with Lasso.

Usage

lasso_deltas(
  X,
  y,
  lambda = NULL,
  verbose = FALSE,
  alpha = 1,
  rank_fn = order_plain,
  k = ncol(X)
)

Value

A matrix - the initial state of Markov Chain for HTLR model fitting.

Arguments

X

Design matrix of traning data; rows should be for the cases, and columns for different features.

y

Vector of class labels in training or test data set. Must be coded as non-negative integers, e.g., 1,2,...,C for C classes.

lambda

A user supplied lambda sequence for glmnet cross-validation. NULL by default, and it will be generated by glmnet.

alpha

The elasticnet mixing parameter for glmnet.

References

Jerome Friedman, Trevor Hastie, Robert Tibshirani (2010). Regularization Paths for Generalized Linear Models via Coordinate Descent. Journal of Statistical Software, 33(1), 1-22.

See Also

bcbcsf_deltas