Based on arguments, this wrapper routes the data and arguments to the four
pls functions that are sparse/dense or regression/classification.
pls_fit(x, y, ncomp = NULL, keepX = NULL, ...)A data frame or matrix of predictors.
For classification, a factor. For regression, a matrix, vector, or data frame.
The number of PLS components. If left null, the maximum possible is used.
The number of non-zero loadings per component. If the value is
a vector, the value is left as-is. Otherwise, the scalar is expanded to be
the same for all components. If NULL, either mixOmics::pls() or
mixOmics::plsda() are used. Otherwise, their sparse analogs are used.
A model object generated by mixOmics::pls(), mixOmics::plsda(),
mixOmics::spls(), or mixOmics::splsda().