## Not run:
# #See ?'crisp-package' for a full example of how to use this package
#
# #generate data (using a very small 'n' for illustration purposes)
# set.seed(1)
# data <- sim.data(n = 15, scenario = 2)
#
# #fit model and select lambda using 2-fold cross-validation
# #note: use larger 'n.fold' (e.g., 10) in practice
# crispCV.out <- crispCV(X = data$X, y = data$y, n.fold = 2)
#
# #plot the cross-validation error
# plot(summary(crispCV.out))
# ## End(Not run)
Run the code above in your browser using DataLab