Description Usage Arguments Value Author(s) See Also Examples
k-fold cross validation for HCgglasso
1 2 3 |
X |
matrix of size n*p |
y |
vector of size n |
nfolds |
number of folds |
lambda |
lambda values for group lasso. If not provided, the function generates its own values of lambda |
hc |
output of |
weightLevel |
a vector of size p for each level of the hierarchy. A zero indicates that the level will be ignored. If not provided, use 1/(height between 2 successive levels) |
weightSizeGroup |
a vector |
intercept |
should an intercept be included in the model ? |
verbose |
print some informations |
... |
Others parameters for |
a cv.HCgglasso object containing :
values of lambda
.
the mean cross-validated error.
estimate of standard error of cvm
upper curve = cvm+cvsd
lower curve = cvm-cvsd
The optimal value of lambda
that gives minimum cross validation error cvm
.
The largest value of lambda
such that error is within 1 standard error of the minimum.
computation time
Quentin Grimonprez
HCgglasso, stability.HCgglasso, predict.cv.gglasso, coef.cv.HCgglasso, plot.cv.HCgglasso
1 2 3 4 | set.seed(42)
X = simuBlockGaussian(50,12,5,0.7)
y = drop(X[,c(2,7,12)]%*%c(2,2,-2)+rnorm(50,0,0.5))
res = cv.HCgglasso(X,y)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.