coda: Chromatogram selection using the CODA algorithm

Description Usage Arguments Details References Examples

View source: R/coda.R

Description

The CODA algorithm calculates a so-called MCQ (Mass Chromatogram Quality) value for every row of the input. High MCQ values correspond with those chromatograms not containing spikes and/or a baseline.

Usage

1
coda(x, window = 5, smoothing = c("median", "mean"))

Arguments

x

data matrix containing chromatograms in the rows

window

width of the smoothing window

smoothing

type of smoothing: whether to use running means or running medians

Details

The MCQ value of a spectrum is the inner product between the standardized, smoothed chromatogram, and the length-scaled chromatogram. In literature, a cut-off of 0.85 has been reported to work well in selecting useful chromatograms, although this is strongly data-set dependent.

References

Windig, W., Phalp, J., Payna, A. (1996) "A noise and background reduction method for component detection in liquid chromatography/mass spectrometry", Analytical Chemistry, 68, 3602 – 3606.

Examples

1
2

Example output

 [1] 0.9841129 0.9832000 0.9857597 0.9850265 0.9846334 0.9860797 0.9854502
 [8] 0.9863466 0.9847776 0.9855435 0.9851256 0.9846632 0.9856389 0.9852633
[15] 0.9846926 0.9845197

ptw documentation built on Jan. 19, 2022, 5:07 p.m.