powered by
Performs Partial Least Squares classification
PLSc(X, Y, A, scaling = 'auto-scaling', post.transformation = TRUE, eps = 0.01, Y.prob = FALSE, transformation = 'ilr')
List with the following objects:
Matrix of weights
Matrix of X loading
X
Matrix of Y loading
Y
Matrix of X data (predictor variables)
Matrix of Y data (dependent variable)
Matrix of scores
Fitted Y matrix
Matrix regression coefficients
Number of orthogonal components if post.transformation=TRUE is applied.
post.transformation=TRUE
Data matrix where columns represent the \(p\) variables and rows the \(n\) observations.
Data matrix where columns represent the two classes and rows the \(n\) observations.
Number of score components
Type of scaling, one of c('auto-scaling', 'pareto-scaling', 'mean-centering'). Default to 'auto-scaling'
c('auto-scaling', 'pareto-scaling', 'mean-centering')
Boolean value. TRUE if you want to apply post transformation. Default TRUE
TRUE
Default 0.01. eps is used when Y.prob = FALSE to transform Y in a probability vector
eps
Y.prob = FALSE
Boolean value. Default FALSE. IF TRUE Y is a probability vector
FALSE
Transformation used to map Y in probability data vector. The options are 'ilr' and 'clr'. Default @ilr.
Angela Andreella
Stocchero, M., De Nardi, M., & Scarpa, B. (2021). PLS for classification. Chemometrics and Intelligent Laboratory Systems, 216, 104374.
datas <- simulatePilotData(nvar = 30, clus.size = c(5,5),m = 6,nvar_rel = 5,A = 2) out <- PLSc(X = datas$X, Y = datas$Y, A = 3)
Run the code above in your browser using DataLab