Learn R Programming

SPUTNIK (version 1.1)

createPeaksFilter: Generate a peak filter object.

Description

createPeaksFilter returns a peak.filter object.

Usage

createPeaksFilter(peaksIndices)

Arguments

peaksIndices

a named array representing the selected peaks. Names correspond to the m/z values.

Value

peak.filter object.

Details

Function to create a custom peak that can be subsequently applied using the function applyPeaksFilter-msi.dataset-method. Argument of the function is the index vector of the selected peaks named with their m/z values. The m/z values are used to check whether the indices correspond to the common m/z values in the msi.dataset-class object.

See Also

applyPeaksFilter-msi.dataset-method

Examples

Run this code
# NOT RUN {
library("SPUTNIK")
mz <- seq(100, 195, 5)
mzIdx <- sample(100, 20)
names(mzIdx) <- mz
peaksFilter <- createPeaksFilter(mzIdx)

# }

Run the code above in your browser using DataLab