ChromatogramExtractorAlgorithm#

class pyopenms.ChromatogramExtractorAlgorithm#

Bases: ProgressLogger

The ChromatogramExtractorAlgorithm extracts chromatograms from a MS data.

It will take as input a set of transitions coordinates and will extract the signal of the provided map at the product ion m/z and retention time (rt) values specified by the extraction coordinates. This interface only expects a set of coordinates which are up to the user to fill but a convenient prepare_coordinates function is provided (in the ChromatogramExtractor class) to create the coordinates for the most common case of an MS2 and MS1 extraction.

In the case of MS2 extraction, the map is assumed to originate from a SWATH (data-independent acquisition or DIA) experiment.

__init__() → None#
__init__(arg: pyopenms.ChromatogramExtractorAlgorithm, /) → None

Methods

__init__()

endProgress([bytes_processed])

Ends the progress display

extractChromatograms(input, output, ...)

Extract chromatograms at the m/z and RT defined by the ExtractionCoordinates

getLogType()

Returns the type of progress log being used

nextProgress()

Increment progress by 1 (according to range begin-end)

setLogType(type)

Sets the progress log that should be used.

setProgress(value)

Sets the current progress

startProgress(begin, end, label)

Attributes

CMD = 0#
GUI = 1#
NONE = 2#
endProgress(bytes_processed: int = 0) → None#

Ends the progress display

extractChromatograms(input: pyopenms.SpectrumAccessOpenMS, output: collections.abc.Sequence[pyopenms.OSChromatogram], extraction_coordinates: collections.abc.Sequence[pyopenms.ExtractionCoordinates], mz_extraction_window: float, ppm: bool, im_extraction_window: float, filter: str) → None#

Extract chromatograms at the m/z and RT defined by the ExtractionCoordinates

Parameters:
  • input – Input spectral map

  • output – Output chromatograms (XICs)

  • extraction_coordinates – Extracts around these coordinates (from rt_start to rt_end in seconds - extracts the whole chromatogram if rt_end - rt_start < 0).

  • mz_extraction_window – Extracts a window of this size in m/z dimension in Th or ppm (e.g. a window of 50 ppm means an extraction of 25 ppm on either side)

  • ppm – Whether mz_extraction_window is in ppm or in Th

  • filter – Which function to apply in m/z space (currently “tophat” only)

getLogType() → pyopenms.ProgressLogger.LogType#

Returns the type of progress log being used

nextProgress() → None#

Increment progress by 1 (according to range begin-end)

setLogType(type: pyopenms.ProgressLogger.LogType) → None#

Sets the progress log that should be used. The default type is NONE!

setProgress(value: int) → None#

Sets the current progress

startProgress(begin: int, end: int, label: str) → None#