Learn R Programming

mdatools (version 0.13.1)

mdatools: Package for Multivariate Data Analysis (Chemometrics)

Description

This package contains classes and functions for most common methods used in Chemometrics. For a complete list of functions, use library(help = 'mdatools').

Arguments

Author

Sergey Kucheryavskiy (svkucheryavski@gmail.com)

Details

The project is hosted on GitHub (https://svkucheryavski.github.io/mdatools/), there you can also find a Bookdown user tutorial explaining most important features of the package. There is also a dedicated YouTube channel (https://www.youtube.com/channel/UCox0H4utfMq4FIu2kymuyTA) with introductory Chemometric course with examples based on mdatools functionality.

Every method is represented by two classes: a model class for keeping all parameters and information about the model, and a class for keeping and visualising results of applying the model to particular data values.

Every model class, e.g. pls, has all needed functionality implemented as class methods, including model calibration, validation (test set and cross-validation), visualisation of the calibration and validation results with various plots and summary statistics.

So far the following modelling and validation methods are implemented:

pca, pcaresPrincipal Component Analysis (PCA).
pls, plsresPartial Least Squares regression (PLS).
simca, simcaresSoft Independent Modelling of Class Analogues (SIMCA)
simcam, simcamresSIMCA for multiple classes case (SIMCA)
plsda, plsdaresPartial Least Squares Dscriminant Analysis (PLS-DA).
randtestRandomization test for PLS-regression.
iplsInterval PLS variable.
mcralsMultivariate Curve Resolution with Alternating Least Squares.
mcrpureMultivariate Curve Resolution with Purity approach.
pcvProcrustes Cross Validation.

Methods for data preprocessing:

prep.autoscaledata mean centering and/or standardization.
prep.savgolSavitzky-Golay transformation.
prep.snvStandard normal variate.
prep.mscMultiplicative scatter correction.
prep.normSpectra normalization.
prep.alsbasecorrBaseline correction with Asymmetric Least Squares.

All plotting methods are based on two functions, mdaplot and mdaplotg. The functions extend the basic functionality of R plots and allow to make automatic legend and color grouping of data points or lines with colorbar legend, automatically adjust axes limits when several data groups are plotted and so on.