Learn R Programming

RKHSMetaMod (version 1.1)

RKHSgrplasso: Function to fit a solution of an RKHS Group Lasso problem.

Description

Fits the solution of an RKHS group lasso problem for the Gaussian regression model.

Usage

RKHSgrplasso(Y, Kv, mu, maxIter, verbose)

Arguments

Y

Vector of response observations of size \(n\).

Kv

List, includes the eigenvalues and eigenvectors of the positive definite Gram matrices \(K_v, v=1,...,\)vMax and their associated group names. It should have the same format as the output of the function calc_Kv (see details).

mu

Positive scalar, value of the penalty parameter \(\mu_g\) in the RKHS Group Lasso problem.

maxIter

Integer, shows the maximum number of loops through all groups. Set as \(1000\) by default.

verbose

Logical, if TRUE, prints: the number of current iteration, active groups and convergence criterias. Set as FALSE by default.

Value

Estimated RKHS meta model, list with \(13\) components:

intercept

Scalar, estimated value of intercept.

teta

Matrix with vMax rows and \(n\) columns. Each row of the matrix is the estimated vector \(\theta_{v}\) for \(v=1,...,\)vMax.

fit.v

Matrix with \(n\) rows and vMax columns. Each row of the matrix is the estimated value of \(f_{v}=K_{v}\theta_{v}\).

fitted

Vector of size \(n\), indicates the estimator of \(m\).

Norm.H

Vector of size vMax, estimated values of the penalty norm.

supp

Vector of active groups.

Nsupp

Vector of the names of the active groups.

SCR

Scalar, equals to \(\Vert Y-f_{0}-\sum_{v}K_{v}\theta_{v}\Vert ^{2}\).

crit

Scalar, indicates the value of penalized criteria.

MaxIter

Integer, number of iterations until convergence is reached.

convergence

TRUE or FALSE. Indicates whether the algorithm has converged or not.

RelDiffCrit

Scalar, value of the first convergence criteria at the last iteration, \(\frac{crit_{lastIter}-crit_{lastIter-1}}{crit_{lastIter-1}}\).

RelDiffPar

Scalar, value of the second convergence criteria at the last iteration, \(\Vert\frac{\theta_{lastIter}-\theta_{lastIter-1}}{\theta_{lastIter-1}}\Vert ^{2}\).

Details

Input Kv should contain the eigenvalues and eigenvectors of positive definite Gram matrices \(K_v\). It is necessary to set input correction in the function calc_Kv equal to "TRUE".

References

Kamari, H., Huet, S. and Taupin, M.-L. (2019) RKHSMetaMod : An R package to estimate the Hoeffding decomposition of an unknown function by solving RKHS Ridge Group Sparse optimization problem. <arXiv:1905.13695>

Meier, L. Van de Geer, S. and Buhlmann, P. (2008) The group LASSO for logistic regression. Journal of the Royal Statistical Society Series B. 70. 53-71. 10.1111/j.1467-9868.2007.00627.x.

See Also

calc_Kv

Examples

Run this code
# NOT RUN {
d <- 3
n <- 50
library(lhs)
X <- maximinLHS(n, d)
c <- c(0.2,0.6,0.8)
F <- 1;for (a in 1:d) F <- F*(abs(4*X[,a]-2)+c[a])/(1+c[a])
epsilon <- rnorm(n,0,1);sigma <- 0.2
Y <- F + sigma*epsilon
Dmax <- 3
kernel <- "matern"
Kv <- calc_Kv(X, kernel, Dmax, TRUE, TRUE)
matZ <- Kv$kv
mumax <- mu_max(Y, matZ)
mug <- mumax/10
gr <- RKHSgrplasso(Y,Kv, mug , 1000, FALSE)
gr$Nsupp
# }

Run the code above in your browser using DataLab