Click or drag to resize

MultivariateRegressionGetCrossPRESS Method

Gets the cross predicted error sum of squares (PRESS) for numberOfFactors = 0..maximalNumberOfFactors.

Namespace: Altaxo.Calc.Regression.Multivariate
Assembly: AltaxoCore (in AltaxoCore.dll) Version: 4.8.3572.0 (4.8.3572.0)
Syntax
C#
public static double GetCrossPRESS(
	double[] xOfXRaw,
	Matrix<double> matrixXRaw,
	Matrix<double> matrixYRaw,
	int maximalNumberOfFactors,
	ICrossValidationGroupingStrategy groupingStrategy,
	ISingleSpectrumPreprocessor spectralPreprocessing,
	MultivariateRegression regressionMethod,
	out IReadOnlyList<double> crossPRESS
)

Parameters

xOfXRaw  Double
The x-values (wavelength, frequency, etc.) of the unpreprocessed spectra.
matrixXRaw  MatrixDouble
Matrix of unpreprocessed spectra (a spectrum is a row in the matrix).
matrixYRaw  MatrixDouble
Matrix of unpreprocessed target variables (e.g. concentrations).
maximalNumberOfFactors  Int32
Maximum number of factors to calculate the cross PRESS for.
groupingStrategy  ICrossValidationGroupingStrategy
The strategy how to group the spectra for cross prediction.
spectralPreprocessing  ISingleSpectrumPreprocessor
Information how to preprocess the spectra, here: how to process each spectrum separately.
regressionMethod  MultivariateRegression
The type of regression (e.g. PCR, PLS1, PLS2) provided as an empty regression object.
crossPRESS  IReadOnlyListDouble
On return, the vector of cross PRESS values. Note that this vector has the length maximalNumberOfFactors + 1.

Return Value

Double
The mean number of spectra used for prediction.
See Also