OpenMS
SiriusExportAlgorithm.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: Oliver Alka, Axel Walter $
6 // $Authors: Oliver Alka, Lukas Zimmermann $
7 // --------------------------------------------------------------------------
8 
9 #pragma once
10 
12 
13 #include <OpenMS/SYSTEM/File.h>
14 
15 #include <QtCore/QStringList>
16 
17 using namespace std;
18 
19 namespace OpenMS
20 {
21  class OPENMS_DLLAPI SiriusExportAlgorithm : public DefaultParamHandler
22  {
23  public:
26 
27  // accessor for preprocessing parameters
28  bool isFeatureOnly() const { return param_.getValue("feature_only").toBool(); }
29  UInt getFilterByNumMassTraces() const { return param_.getValue("filter_by_num_masstraces"); }
30  double getPrecursorMzTolerance() const { return param_.getValue("precursor_mz_tolerance"); }
31  double getPrecursorRtTolerance() const { return param_.getValue("precursor_rt_tolerance"); }
32  bool precursorMzToleranceUnitIsPPM() const { return param_.getValue("precursor_mz_tolerance_unit") == "ppm"; }
33  bool isNoMasstraceInfoIsotopePattern() const { return param_.getValue("no_masstrace_info_isotope_pattern").toBool(); }
34  int getIsotopePatternIterations() const { return param_.getValue("isotope_pattern_iterations"); }
35 
46  void preprocessing(const String& featureinfo,
47  const MSExperiment& spectra,
48  FeatureMapping::FeatureMappingInfo& feature_mapping_info,
49  FeatureMapping::FeatureToMs2Indices& feature_ms2_indices) const;
50 
60  void logFeatureSpectraNumber(const String& featureinfo,
61  const FeatureMapping::FeatureToMs2Indices& feature_ms2_indices,
62  const MSExperiment& spectra) const;
63 
75  void run(const StringList& mzML_files,
76  const StringList& featureXML_files,
77  const String& out_ms,
78  const String& out_compoundinfo) const;
79 
80  };
81 } // namespace OpenMS
A base class for all classes handling default parameters.
Definition: DefaultParamHandler.h:66
Stores information required for preprocessing.
Definition: FeatureMapping.h:25
Stores preprocessed feature mapping information.
Definition: FeatureMapping.h:33
In-Memory representation of a mass spectrometry run.
Definition: MSExperiment.h:46
Definition: SiriusExportAlgorithm.h:22
void logFeatureSpectraNumber(const String &featureinfo, const FeatureMapping::FeatureToMs2Indices &feature_ms2_indices, const MSExperiment &spectra) const
logs number of features and spectra used
double getPrecursorMzTolerance() const
Definition: SiriusExportAlgorithm.h:30
bool isNoMasstraceInfoIsotopePattern() const
Definition: SiriusExportAlgorithm.h:33
bool isFeatureOnly() const
Definition: SiriusExportAlgorithm.h:28
SiriusExportAlgorithm()
default constructor
double getPrecursorRtTolerance() const
Definition: SiriusExportAlgorithm.h:31
bool precursorMzToleranceUnitIsPPM() const
Definition: SiriusExportAlgorithm.h:32
void run(const StringList &mzML_files, const StringList &featureXML_files, const String &out_ms, const String &out_compoundinfo) const
exports SIRIUS .ms file
void preprocessing(const String &featureinfo, const MSExperiment &spectra, FeatureMapping::FeatureMappingInfo &feature_mapping_info, FeatureMapping::FeatureToMs2Indices &feature_ms2_indices) const
Preprocessing needed for SIRIUS and AssayGeneratorMetabo.
UInt getFilterByNumMassTraces() const
Definition: SiriusExportAlgorithm.h:29
int getIsotopePatternIterations() const
Definition: SiriusExportAlgorithm.h:34
A more convenient string class.
Definition: String.h:34
unsigned int UInt
Unsigned integer type.
Definition: Types.h:64
std::vector< String > StringList
Vector of String.
Definition: ListUtils.h:44
Main OpenMS namespace.
Definition: openswathalgo/include/OpenMS/OPENSWATHALGO/DATAACCESS/ISpectrumAccess.h:19