View source: R/FunctionsALasso.R
1 2 3 4 5 6 7 | adaplassostdseq_lambda(
Xstd,
Ystd,
tuning_seq = NULL,
len_tuning = 60,
eps = 0.001
)
|
Xstd |
n x p design matrix X scaled according to LARS algorithm and centered to mean 0 |
Ystd |
n x 1 centered output vector |
tuning_seq |
(optional)sequence of tuning parameters |
len_tuning |
length of desired tuning parameter sequence |
eps |
precision level for convergence assessment, default 0.001 |
tuning_seq |
the actual sequence of tuning parameters used |
beta_lamb |
matrix of solutions at each lambda value for a given gamma, dimension is p x len_tuning \itemobj_min_vecvector of optimal values of the objective function for each lambda at solution |
Fits Adaptive adaplasso on a sequence of lambda values based on standardized data X <- matrix(rnorm(500), 50, 10) Y <- rnorm(50) gamma <- 2 #Standardizing X and Y std <- standardize(X , Y , gamma) #Deriving weighted and centered design matrix Xstd <- std$Xstd #Deriving centered Y Ystd <- std$Ystd fit <- adaplassostdseq_lambda(Xstd, Ystd)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.