11#include <OpenMS/config.h>
90 std::map<std::string, MRMFeatureSelector::LambdaScore>& sw
94 select_transition_group(stg),
95 segment_window_length(swl),
96 segment_step_length(ssl),
98 optimal_threshold(ot),
102 bool locality_weight =
false;
103 bool select_transition_group =
true;
104 Int segment_window_length = 8;
105 Int segment_step_length = 4;
107 double optimal_threshold = 0.5;
122 const std::vector<std::pair<double, std::string>>& time_to_name,
123 const std::map<std::string, std::vector<Feature>>& feature_name_map,
124 std::vector<std::string>& result,
158 const std::string& name,
189 const std::vector<Int>& indices,
190 const std::vector<double>& values,
191 const std::string& name,
210 std::vector<std::pair<double, std::string>>& time_to_name,
211 std::map<std::string, std::vector<Feature>>& feature_name_map,
212 const bool select_transition_group
271 const std::vector<std::pair<double, std::string>>& time_to_name,
272 const std::map<std::string, std::vector<Feature>>& feature_name_map,
273 std::vector<std::string>& result,
310 const std::vector<std::pair<double, std::string>>& time_to_name,
311 const std::map<std::string, std::vector<Feature>>& feature_name_map,
312 std::vector<std::string>& result,
325 std::vector<std::pair<double, std::string>>& time_to_name,
326 std::map<std::string, std::vector<Feature>>& feature_name_map,
327 const bool select_transition_group
A container for features.
Definition FeatureMap.h:78
An LC-MS feature.
Definition Feature.h:46
A wrapper class for linear programming (LP) solvers.
Definition LPWrapper.h:71
Type
Enumeration for variable/constraint bound types.
Definition LPWrapper.h:119
MRMFeatureSelector implementation that selects MRM features via a quadratic-programming formulation o...
Definition MRMFeatureSelector.h:252
void optimize(const std::vector< std::pair< double, std::string > > &time_to_name, const std::map< std::string, std::vector< Feature > > &feature_name_map, std::vector< std::string > &result, const SelectorParameters ¶meters) const override
Build the quadratic LP problem for time_to_name and write the names of selected features to result.
MRMFeatureSelector implementation that selects MRM features via a linear program with score-weighted ...
Definition MRMFeatureSelector.h:291
void optimize(const std::vector< std::pair< double, std::string > > &time_to_name, const std::map< std::string, std::vector< Feature > > &feature_name_map, std::vector< std::string > &result, const SelectorParameters ¶meters) const override
Build the linear program for time_to_name and write the names of selected features to result.
Definition MRMFeatureSelector.h:318
MRMFeatureSelectorQMIP selector_
Definition MRMFeatureSelector.h:348
double weightScore_(const double score, const LambdaScore lambda_score) const
Definition MRMFeatureSelector.h:333
std::string removeSpaces_(std::string str) const
Definition MRMFeatureSelector.h:343
void constructTargTransList_(const FeatureMap &features, std::vector< std::pair< double, std::string > > &time_to_name, std::map< std::string, std::vector< Feature > > &feature_name_map, const bool select_transition_group) const
Definition MRMFeatureSelector.h:323
MRMFeatureSelector_test()=default
~MRMFeatureSelector_test() override=default
double computeScore_(const Feature &feature, const std::map< std::string, LambdaScore > &score_weights) const
Definition MRMFeatureSelector.h:338
A base class for selection of MRM Features through Linear Programming optimization.
Definition MRMFeatureSelector.h:52
virtual ~MRMFeatureSelector()=default
MRMFeatureSelector()=default
LambdaScore
Definition MRMFeatureSelector.h:64
void selectMRMFeature(const FeatureMap &features, FeatureMap &selected_filtered, const SelectorParameters ¶meters) const
double weightScore_(const double score, const LambdaScore lambda_score) const
std::string removeSpaces_(std::string str) const
Removes spaces from the given string, not-in-place.
void constructTargTransList_(const FeatureMap &features, std::vector< std::pair< double, std::string > > &time_to_name, std::map< std::string, std::vector< Feature > > &feature_name_map, const bool select_transition_group) const
virtual void optimize(const std::vector< std::pair< double, std::string > > &time_to_name, const std::map< std::string, std::vector< Feature > > &feature_name_map, std::vector< std::string > &result, const SelectorParameters ¶meters) const =0
void addConstraint_(LPWrapper &problem, const std::vector< Int > &indices, const std::vector< double > &values, const std::string &name, const double lb, const double ub, const LPWrapper::Type param) const
Int addVariable_(LPWrapper &problem, const std::string &name, const bool bounded, const double obj, const VariableType variableType) const
VariableType
Definition MRMFeatureSelector.h:58
double computeScore_(const Feature &feature, const std::map< std::string, LambdaScore > &score_weights) const
int Int
Signed integer type.
Definition Types.h:72
Main OpenMS namespace.
Definition openswathalgo/include/OpenMS/OPENSWATHALGO/DATAACCESS/ISpectrumAccess.h:19
Definition MRMFeatureSelector.h:79
SelectorParameters()=default
std::map< std::string, MRMFeatureSelector::LambdaScore > score_weights
Weights for the scores.
Definition MRMFeatureSelector.h:108
SelectorParameters(Int nn, bool lw, bool stg, Int swl, Int ssl, MRMFeatureSelector::VariableType vt, double ot, std::map< std::string, MRMFeatureSelector::LambdaScore > &sw)
Definition MRMFeatureSelector.h:82