m_prcomp: Multiway Principal Component Analysis

Description Usage Arguments Value References Examples

View source: R/m_prcomp.R

Description

'm_prcomp' Performs a multiway principal components analysis on a given two-dimensional chromatograms and returns the rusults as object of class MPCA. Before to perform the calculation, each given chromatogramas are unfolded to a single dimension. All chromatograms are merged and principal component analysis is performed with the built-in prcomp function. The print method for these objects prints the summary of the analysis. This algorithm was first presented by \insertCiteWold1987RGCxGC.

Usage

1
m_prcomp(chrom, center = FALSE, scale = FALSE, npcs = 3, ...)

Arguments

chrom

Multiple chromatograms readed or batch aligned

center

A logical value indicating whether the variables should be shifted to be zero centered. FALSE is set by default.

scale

a logical value indicating whether the variables should be scaled to have unit variance before the analysis takes place. The default is FALSE.

npcs

an integer indicating how many principals components are desired to mantain. The default is 3 principal components.

...

Other argments passed to prcomp function.

Value

MPCA returns a list whit class "MPCA" containing the summary of the analysis, the scores matrix, unfolded loadings, and the metadata if it was provided when chromatograms were joined.

References

\insertAllCited

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
data(MTBLS579)

# Perform multiway principal component analysis
MTBLS579_mpca <- m_prcomp(MTBLS579)
# Print MPCA summary
print(MTBLS579_mpca)
# Retrieve MPCA scores
scores(MTBLS579_mpca)
# Plot bidimensional scores
plot_loading(MTBLS579_mpca)

DanielQuiroz97/RGCxGC documentation built on Feb. 14, 2020, 1:35 a.m.