estim.regul: Estimate the parameters of regularization

Description Usage Arguments Value Author(s) See Also Examples

Description

Calulate the leave-one-out criterion on a 2D-grid to determine optimal values for the parameters of regularization.

Usage

1
estim.regul(X, Y, grid1 = NULL, grid2 = NULL, plt = TRUE)

Arguments

X

numeric matrix (n * p), containing the X coordinates.

Y

numeric matrix (n * p), containing the X coordinates.

grid1

vector defining the values of lambda1 to be tested. If NULL, the vector is defined as seq(0.001, 1, length = 5)

grid2

vector defining the values of lambda2 to be tested. If NULL, the vector is defined as seq(0.001, 1, length = 5)

plt

logical argument indicating whether an image should be plotted by calling the img.estim.regul() function.

Value

A 3-vector containing the 2 values of the parameters of regularization on which the leave-one-out criterion reached its maximum; and the maximal value reached on the grid.

Author(s)

Sébastien Déjean, Ignacio González

See Also

loo

Examples

1
2
3
4
#data(nutrimouse)
#X=as.matrix(nutrimouse$gene)
#Y=as.matrix(nutrimouse$lipid)
#res.regul = estim.regul(X,Y,c(0.01,0.5),c(0.1,0.2,0.3)) 

CCA documentation built on March 1, 2021, 9:06 a.m.