## cv.biglasso
seed <- 1234
data(prostate)
X <- as.matrix(prostate[,1:8])
y <- prostate$lpsa
X <- as.big.matrix(X)
# run in series
cvfit <- cv.biglasso(X, y, family = 'gaussian', seed = seed)
par(mfrow = c(2, 2))
plot(cvfit, type = 'all')
summary(cvfit)
# run in parallel
## Not run:
# cvfit2 <- cv.biglasso(X, y, family = 'gaussian', seed = seed, ncores = 5)
# plot(cvfit2)
# summary(cvfit2)
# stopifnot(identical(cvfit, cvfit2))
# ## End(Not run)
Run the code above in your browser using DataLab