Learn R Programming

resemble (version 2.1.2)

reconstruction_error: Projection to pls and then re-construction

Description

Projects spectra onto a PLS space and then reconstructs it back.

Usage

reconstruction_error(x, projection_mat, xloadings, scale, Xcenter, Xscale)

Value

a matrix of 1 row and 1 column.

Arguments

x

a matrix to project.

projection_mat

the projection matrix generated by the opls_get_basics function.

xloadings

the loadings matrix generated by the opls_get_basics function.

scale

logical indicating if scaling is required

Xcenter

a matrix of one row with the centering values

Xscale

a matrix of one row with the scaling values

Author

Leonardo Ramirez-Lopez