Computes orthogonal socres partial least squares (opls)
regressions with the NIPALS algorithm. It allows multiple response variables.
In contrast to opls
function, this one does not compute unnecessary
data for (local) regression.
For internal use only!
opls_get_basics(X, Y, ncomp, scale,
maxiter, tol,
algorithm = "pls",
xls_min_w = 3,
xls_max_w = 15)
a list containing the following elements:
coefficients
: the matrix of regression coefficients.
bo
: a matrix of one row containing the intercepts for each component.
Y_loadings
: the matrix of Y loadings.
projection_mat
: the projection matrix.
transf
: a list
conating two objects: Xcenter
and Xscale
.
a matrix of predictor variables.
a matrix of either a single or multiple response variables.
the number of pls components.
logical indicating whether X
must be scaled.
maximum number of iterations.
limit for convergence of the algorithm in the nipals algorithm.
(for weights computation) a character string indicating
what method to use. Options are:
'pls'
for pls (using covariance between X and Y),
'mpls'
for modified pls (using correlation between X and Y) or
'xls'
for extended pls (as implemented in BUCHI NIRWise PLUS software).
(for weights computation) an integer indicating the minimum window size for the "xls"
method. Only used if algorithm = 'xls'
. Default is 3 (as in BUCHI NIRWise PLUS software).
(for weights computation) an integer indicating the maximum window size for the "xls"
method. Only used if algorithm = 'xls'
. Default is 15 (as in BUCHI NIRWise PLUS software).
Leonardo Ramirez-Lopez