OpenMS
Loading...
Searching...
No Matches
MRMFeature.h
Go to the documentation of this file.
1// Copyright (c) 2002-present, OpenMS Inc. -- EKU Tuebingen, ETH Zurich, and FU Berlin
2// SPDX-License-Identifier: BSD-3-Clause
3//
4// --------------------------------------------------------------------------
5// $Maintainer: Hannes Roest $
6// $Authors: Hannes Roest $
7// --------------------------------------------------------------------------
8
9#pragma once
10
13
14namespace OpenMS
15{
24 class OPENMS_DLLAPI MRMFeature :
25 public Feature
26 {
27public:
28
30
31
32 typedef std::vector<Feature> FeatureListType;
34
36
37
39
42
44 MRMFeature(MRMFeature &&rhs) = default;
45
48
51
53 ~MRMFeature() override;
55
57
58
60 const OpenSwath_Scores & getScores() const;
61
64
66 Feature & getFeature(const String& key);
67
69 const Feature & getFeature(const String& key) const;
70
72 void setScores(const OpenSwath_Scores & scores);
73
75 void addScore(const String & score_name, double score);
76
78 void addFeature(const Feature & feature, const String& key);
79
80 void addFeature(Feature && feature, const String& key);
81
83 const std::vector<Feature> & getFeatures() const;
84
86 void getFeatureIDs(std::vector<String> & result) const;
87
89 void addPrecursorFeature(const Feature & feature, const String& key);
90
91 void addPrecursorFeature(Feature && feature, const String& key);
92
94 void getPrecursorFeatureIDs(std::vector<String> & result) const;
95
98
100 const Feature & getPrecursorFeature(const String& key) const;
101
102 void IDScoresAsMetaValue(bool decoy, const OpenSwath_Ind_Scores& idscores);
104
105protected:
106
108
110
113
115 std::map<String, int> feature_map_;
116
118 std::map<String, int> precursor_feature_map_;
119
120 };
121}
122
123
An LC-MS feature.
Definition Feature.h:46
A multi-chromatogram MRM feature.
Definition MRMFeature.h:26
Feature & getPrecursorFeature(const String &key)
get a specified precursor feature
void addFeature(Feature &&feature, const String &key)
std::vector< Feature > FeatureListType
Type definitions.
Definition MRMFeature.h:32
const Feature & getFeature(const String &key) const
get a specified feature (const)
const Feature & getPrecursorFeature(const String &key) const
get a specified precursor feature (const)
void getPrecursorFeatureIDs(std::vector< String > &result) const
get a list of IDs of available precursor features
OpenSwath_Scores pg_scores_
peak group scores
Definition MRMFeature.h:112
void addPrecursorFeature(Feature &&feature, const String &key)
MRMFeature()
Default constructor.
MRMFeature & operator=(MRMFeature &&) &=default
Move assignment operator.
OpenSwath_Scores & getScores()
get all peakgroup scores
~MRMFeature() override
Destructor.
MRMFeature(MRMFeature &&rhs)=default
Move constructor.
std::map< String, int > precursor_feature_map_
map native ids to the precursor features
Definition MRMFeature.h:118
void setScores(const OpenSwath_Scores &scores)
set all peakgroup scores
void addScore(const String &score_name, double score)
set a single peakgroup score
MRMFeature(const MRMFeature &rhs)
Copy constructor.
MRMFeature & operator=(const MRMFeature &rhs)
Assignment operator.
Feature & getFeature(const String &key)
get a specified feature
void addFeature(const Feature &feature, const String &key)
Adds an feature from a single chromatogram into the feature.
std::map< String, int > feature_map_
map native ids to the features
Definition MRMFeature.h:115
const std::vector< Feature > & getFeatures() const
get a list of features
void addPrecursorFeature(const Feature &feature, const String &key)
Adds a precursor feature from a single chromatogram into the feature.
const OpenSwath_Scores & getScores() const
get all peakgroup scores
void getFeatureIDs(std::vector< String > &result) const
get a list of IDs of available features
FeatureListType features_
Definition MRMFeature.h:107
void IDScoresAsMetaValue(bool decoy, const OpenSwath_Ind_Scores &idscores)
FeatureListType precursor_features_
Definition MRMFeature.h:109
A more convenient string class.
Definition String.h:34
Main OpenMS namespace.
Definition openswathalgo/include/OpenMS/OPENSWATHALGO/DATAACCESS/ISpectrumAccess.h:19
A structure to hold the individual scores computed for unique ion signatures (UIS) scores for the Inf...
Definition OpenSwathScores.h:181
A structure to hold the different scores computed by OpenSWATH.
Definition OpenSwathScores.h:57