findEIC: Extract EICs

Description Usage Arguments Value Author(s) See Also

View source: R/leMsmsRaw.R

Description

Extract EICs from raw data for a determined mass window.

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
findEIC(
  msRaw,
  mz,
  limit = NULL,
  rtLimit = NA,
  headerCache = NULL,
  floatingRecalibration = NULL,
  peaksCache = NULL,
  polarity = NA,
  msLevel = 1,
  precursor = NULL
)

Arguments

msRaw

The mzR file handle

mz

The mass or mass range to extract the EIC for: either a single mass (with the range specified by limit below) or a mass range in the form of c(min, max).

limit

If a single mass was given for mz: the mass window to extract. A limit of 0.001 means that the EIC will be returned for [mz - 0.001, mz + 0.001].

rtLimit

If given, the retention time limits in form c(rtmin, rtmax) in seconds.

headerCache

If present, the complete mzR::header(msRaw). Passing this value is useful if spectra for multiple compounds should be extracted from the same mzML file, since it avoids getting the data freshly from msRaw for every compound.

floatingRecalibration

A fitting function that predict()s a mass shift based on the retention time. Can be used if a lockmass calibration is known (however you have to build the calibration yourself.)

peaksCache

If present, the complete output of mzR::peaks(msRaw). This speeds up the lookup if multiple compounds should be searched in the same file.

Value

A [rt, intensity, scan] matrix (scan being the scan number.)

Author(s)

Michael A. Stravs, Eawag <michael.stravs@eawag.ch>

See Also

findMsMsHR


sneumann/RMassBank documentation built on Oct. 20, 2020, 3:19 p.m.