OpenMS
FIAMSDataProcessor.h
Go to the documentation of this file.
1 // Copyright (c) 2002-present, The OpenMS Team -- EKU Tuebingen, ETH Zurich, and FU Berlin
2 // SPDX-License-Identifier: BSD-3-Clause
3 //
4 // --------------------------------------------------------------------------
5 // $Maintainer: Svetlana Kutuzova, Douglas McCloskey $
6 // $Authors: Svetlana Kutuzova, Douglas McCloskey $
7 // --------------------------------------------------------------------------
8 
9 #pragma once
12 #include <OpenMS/FORMAT/MzTab.h>
13 #include <OpenMS/FORMAT/MzTabM.h>
15 
16 namespace OpenMS
17 {
33  class OPENMS_DLLAPI FIAMSDataProcessor :
34  public DefaultParamHandler
35  {
36 public:
39 
41  ~FIAMSDataProcessor() override = default;
42 
44  FIAMSDataProcessor(const FIAMSDataProcessor& cp) = default;
45 
48 
69  bool run(const MSExperiment& experiment, const float n_seconds, OpenMS::MzTab& output, const bool load_cached_spectrum = true);
70 
78  void cutForTime(const MSExperiment& experiment, const float n_seconds, std::vector<MSSpectrum>& output);
79 
90  MSSpectrum mergeAlongTime(const std::vector<OpenMS::MSSpectrum>& input);
91 
99 
109 
119 
129 
133  const std::vector<float>& getMZs();
134 
138  const std::vector<float>& getBinSizes();
139 
140 protected:
141  void updateMembers_() override;
142 
143 private:
147  void storeSpectrum_(const MSSpectrum& input, const String& filename);
148 
149  std::vector<float> mzs_;
150  std::vector<float> bin_sizes_;
153  };
154 } // namespace OpenMS
A base class for all classes handling default parameters.
Definition: DefaultParamHandler.h:66
Data processing for FIA-MS data.
Definition: FIAMSDataProcessor.h:35
std::vector< float > bin_sizes_
Definition: FIAMSDataProcessor.h:150
MSSpectrum mergeAlongTime(const std::vector< OpenMS::MSSpectrum > &input)
Sum the spectra with different retention times into one.
SavitzkyGolayFilter sgfilter_
Definition: FIAMSDataProcessor.h:151
void cutForTime(const MSExperiment &experiment, const float n_seconds, std::vector< MSSpectrum > &output)
Cut the time axis of the experiment from 0 to n_seconds.
MSSpectrum extractPeaks(const MSSpectrum &input)
Pick peaks from the summed spectrum.
PeakPickerHiRes picker_
Definition: FIAMSDataProcessor.h:152
MSSpectrum trackNoise(const MSSpectrum &input)
Estimate noise for each peak.
const std::vector< float > & getMZs()
Get mass-to-charge ratios to base the summing the spectra along the time axis upon.
void storeSpectrum_(const MSSpectrum &input, const String &filename)
Store the spectrum to the given filepath.
bool run(const MSExperiment &experiment, const float n_seconds, OpenMS::MzTab &output, const bool load_cached_spectrum=true)
Run the full analysis for the experiment for the given time interval.
~FIAMSDataProcessor() override=default
Default destructor.
FIAMSDataProcessor & operator=(const FIAMSDataProcessor &fdp)=default
Assignment.
void updateMembers_() override
This method is used to update extra member variables at the end of the setParameters() method.
FIAMSDataProcessor()
Constructor.
void runAccurateMassSearch(FeatureMap &input, OpenMS::MzTab &output)
Perform accurate mass search.
std::vector< float > mzs_
Definition: FIAMSDataProcessor.h:149
FIAMSDataProcessor(const FIAMSDataProcessor &cp)=default
Copy constructor.
const std::vector< float > & getBinSizes()
Get the sliding bin sizes for summing the spectra along the time axis.
FeatureMap convertToFeatureMap(const MSSpectrum &input)
Convert a spectrum to a feature map with the corresponding polarity.
A container for features.
Definition: FeatureMap.h:80
In-Memory representation of a mass spectrometry run.
Definition: MSExperiment.h:45
The representation of a 1D spectrum.
Definition: MSSpectrum.h:44
Data model of MzTab files. Please see the official MzTab specification at https://code....
Definition: MzTab.h:452
This class implements a fast peak-picking algorithm best suited for high resolution MS data (FT-ICR-M...
Definition: PeakPickerHiRes.h:58
Computes the Savitzky-Golay filter coefficients using QR decomposition.
Definition: SavitzkyGolayFilter.h:78
A more convenient string class.
Definition: String.h:34
Main OpenMS namespace.
Definition: openswathalgo/include/OpenMS/OPENSWATHALGO/DATAACCESS/ISpectrumAccess.h:19