Description Usage Arguments Details Value Author(s) See Also Examples
Computes leaveoneout or Mfold crossvalidation scores on a
twodimensional grid to determine optimal values for the parameters of
regularization in rcc
.
1 2 3 4 5 6 7 8 9 
X 
numeric matrix or data frame (n \times p), the observations
on the X variables. 
Y 
numeric matrix or data frame (n \times q), the observations
on the Y variables. 
grid1, grid2 
vector numeric defining the values of 
validation 
character string. What kind of (internal) crossvalidation
method to use, (partially) matching one of 
folds 
positive integer. Number of folds to use if

plot 
logical argument indicating whether a image map should be
plotted by calling the 
If validation="Mfolds"
, Mfold crossvalidation is performed by
calling Mfold
. When folds
is given, the elements of
folds
should be integer vectors specifying the indices of the
validation sample and the argument M
is ignored. Otherwise, the folds
are generated. The number of crossvalidation folds is specified with the
argument M
.
If validation="loo"
, leaveoneout crossvalidation is performed by
calling the loo
function. In this case the arguments folds
and
M
are ignored.
The estimation of the missing values can be performed by the reconstitution
of the data matrix using the nipals
function. Otherwise, missing
values are handled by casewise deletion in the rcc
function.
The returned value is a list with components:
opt.lambda1, 

opt.lambda2 
value of the parameters of regularization on which the crossvalidation method reached it optimal. 
opt.score 
the optimal crossvalidation score reached on the grid. 
grid1, grid2 
original
vectors 
mat 
matrix containing the crossvalidation score computed on the grid. 
Sébastien Déjean, Ignacio González, KimAnh Lê Cao, Al J Abadi
image.tune.rcc
and http://www.mixOmics.org for more
details.
1 2 3 4 5 6 7  data(nutrimouse)
X < nutrimouse$lipid
Y < nutrimouse$gene
## this can take some seconds
tune.rcc(X, Y, validation = "Mfold")

Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.