cv.multivar | R Documentation |
Cross Validation for multivar
cv.multivar(object)
object |
multivar object built using |
The main function of the multivar package. Performs cross validation to select penalty parameters over a training sample and evaluates them over a test set.
An object of class multivar.results
.
# example 1 (run) sim1 <- multivar_sim( k = 2, # individuals d = 5, # number of variables n = 20, # number of timepoints prop_fill_com = 0.1, # proportion of paths common prop_fill_ind = 0.05, # proportion of paths unique lb = 0.1, # lower bound on coefficient magnitude ub = 0.5, # upper bound on coefficient magnitude sigma = diag(5) # noise ) model1 <- constructModel(data = sim1$data) fit1 <- multivar::cv.multivar(model1)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.