alignPeaks: Compact peak alignment process for 'MassPeaks' objects

View source: R/alignPeaks.R

alignPeaksR Documentation

Compact peak alignment process for MassPeaks objects

Description

This function provides a single command for selecting anchor peaks, peak alignment and binning of MassPeaks class objects (MALDIquant package). It also deals with alignment-related issues found in high-resolution mass spectrometry data.

Usage

alignPeaks(x, minFreq = 0.9, tolerance = 0.003, ...)

Arguments

x

A list of MassPeaks class objects.

minFreq

Minimum relative frequency of a peak over x to be considered as anchor peak for alignment (see referencePeaks).

tolerance

Maximal deviation in peak masses to be considered as identical (see referencePeaks, binPeaks).

...

Details

See warpMassPeaks and binPeaks in the MALDIquant package for details about the alignment and binning algorithms. Note that alignPeaks applies an additional binning round which helps to correct for misalignment issues found after using the default strict or relaxed bin creation rules in high-resolution mass spectrometry data.

Value

A list of MassPeaks class objects with aligned peaks along a common m/z range.

Examples

# Load example data

data(spectra) # list of MassSpectra class objects

# Some pre-processing

spectra <- screenSpectra(spectra)$fspectra
spectra <- transformIntensity(spectra, method = "sqrt")
spectra <- wavSmoothing(spectra)
spectra <- removeBaseline(spectra)
peaks <- detectPeaks(spectra)

# Peak alignment

peaks <- alignPeaks(peaks, minFreq = 0.8)


MALDIrppa documentation built on March 29, 2022, 1:05 a.m.