Home  · Classes  · Annotated Classes  · Modules  · Members  · Namespaces  · Related Pages
Classes | Public Member Functions | Private Member Functions | List of all members
ChromatogramExtractorAlgorithm Class Reference

The ChromatogramExtractorAlgorithm extracts chromatograms from a MS data. More...

#include <OpenMS/ANALYSIS/OPENSWATH/ChromatogramExtractorAlgorithm.h>

Inheritance diagram for ChromatogramExtractorAlgorithm:
ProgressLogger

Classes

struct  ExtractionCoordinates
 

Public Member Functions

void extractChromatograms (const OpenSwath::SpectrumAccessPtr input, std::vector< OpenSwath::ChromatogramPtr > &output, std::vector< ExtractionCoordinates > extraction_coordinates, double mz_extraction_window, bool ppm, String filter)
 Extract chromatograms at the m/z and RT defined by the ExtractionCoordinates. More...
 
void extract_value_tophat (const std::vector< double >::const_iterator &mz_start, std::vector< double >::const_iterator &mz_it, const std::vector< double >::const_iterator &mz_end, std::vector< double >::const_iterator &int_it, const double &mz, double &integrated_intensity, const double &mz_extraction_window, bool ppm)
 Extract the next mz value and add the integrated intensity to integrated_intensity. More...
 
- Public Member Functions inherited from ProgressLogger
 ProgressLogger ()
 Constructor. More...
 
 ~ProgressLogger ()
 Destructor. More...
 
 ProgressLogger (const ProgressLogger &other)
 Copy constructor. More...
 
ProgressLoggeroperator= (const ProgressLogger &other)
 Assignment Operator. More...
 
void setLogType (LogType type) const
 Sets the progress log that should be used. The default type is NONE! More...
 
LogType getLogType () const
 Returns the type of progress log being used. More...
 
void startProgress (SignedSize begin, SignedSize end, const String &label) const
 Initializes the progress display. More...
 
void setProgress (SignedSize value) const
 Sets the current progress. More...
 
void endProgress () const
 Ends the progress display. More...
 

Private Member Functions

int getFilterNr_ (String filter)
 

Additional Inherited Members

- Public Types inherited from ProgressLogger
enum  LogType { CMD, GUI, NONE }
 Possible log types. More...
 
- Static Protected Member Functions inherited from ProgressLogger
static String logTypeToFactoryName_ (LogType type)
 Return the name of the factory product used for this log type. More...
 
- Protected Attributes inherited from ProgressLogger
LogType type_
 
time_t last_invoke_
 
ProgressLoggerImplcurrent_logger_
 
- Static Protected Attributes inherited from ProgressLogger
static int recursion_depth_
 

Detailed Description

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.

Member Function Documentation

◆ extract_value_tophat()

void extract_value_tophat ( const std::vector< double >::const_iterator &  mz_start,
std::vector< double >::const_iterator &  mz_it,
const std::vector< double >::const_iterator &  mz_end,
std::vector< double >::const_iterator &  int_it,
const double mz,
double integrated_intensity,
const double mz_extraction_window,
bool  ppm 
)

Extract the next mz value and add the integrated intensity to integrated_intensity.

This function will sum up all intensities within mz +/- mz_extract_window / 2.0 and add the result to integrated_intensity.

Parameters
mz_extraction_windowExtracts a window of this size in m/z dimension (e.g. a window of 50 ppm means an extraction of 25 ppm on either side)
Note
It will change the position of the iterators mz_it and int_it and it can *not* extract any data if the mz-iterator is already passed the mz value given. It is thus critically important to provide all mz values to be extracted in ascending order!

◆ extractChromatograms()

void extractChromatograms ( const OpenSwath::SpectrumAccessPtr  input,
std::vector< OpenSwath::ChromatogramPtr > &  output,
std::vector< ExtractionCoordinates extraction_coordinates,
double  mz_extraction_window,
bool  ppm,
String  filter 
)

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

Parameters
inputInput spectral map
outputOutput chromatograms (XICs)
extraction_coordinatesExtracts around these coordinates (from rt_start to rt_end in seconds - extracts the whole chromatogram if rt_end - rt_start < 0).
mz_extraction_windowExtracts 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)
ppmWhether mz_extraction_window is in ppm or in Th
filterWhich function to apply in m/z space (currently "tophat" only)

Referenced by ChromatogramExtractor::extractChromatograms().

◆ getFilterNr_()

int getFilterNr_ ( String  filter)
private

OpenMS / TOPP release 2.3.0 Documentation generated on Tue Jan 9 2018 18:22:07 using doxygen 1.8.13