set.seed(123)
# simulate covariates (pure noise in two blocks of 20 and 80 variables)
X <- cbind(matrix(rnorm(4000, 0, 1), ncol = 20), matrix(rnorm(16000, 2, 0.6), ncol = 80))
p <- c(20,80)
# stratum membership
stratum <- sort(rep(1:100, 2))
# the response
Y <- rep(c(1, 0), 100)
# list of L1 penalties
lambda.list = list(c(0.5,1), c(2,0.9))
# perform stability selection
# \donttest{
stable.g1 <- stable.clr.g(response = Y, penalized = X, stratum = stratum,
p = p, lambda.list = lambda.list)# }
Run the code above in your browser using DataLab