| OpenMS 2.5.0

Public Member Functions | Private Member Functions | Private Attributes | List of all members
MRMFeatureFilter Class Reference

The MRMFeatureFilter either flags components and/or transitions that do not pass the QC criteria or filters out components and/or transitions that do not pass the QC criteria. More...

`#include <OpenMS/ANALYSIS/OPENSWATH/MRMFeatureFilter.h>`

Inheritance diagram for MRMFeatureFilter:

## Public Member Functions

void | getDefaultParameters (Param &params) const
| Get the class' default parameters. More...
void | updateMembers_ () override
| Synchronize members with param class. More...
void | FilterFeatureMap (FeatureMap &features, const MRMFeatureQC &filter_criteria, const TargetedExperiment &transitions)
| Flags or filters features and subordinates in a FeatureMap. More...
void | FeatureMapToAttachment (FeatureMap &features, QcMLFile::Attachment &attachment)
| Converts a FeatureMap to a qcMLFile::Attachment. More...
double | calculateIonRatio (const Feature &component_1, const Feature &component_2, const String &feature_name)
| Calculates the ion ratio between two transitions. More...
double | calculateRTDifference (Feature &component_1, Feature &component_2)
| Calculates the retention time difference between two features. More...
double | calculateResolution (Feature &component_1, Feature &component_2)
| Calculates the resolution between two features. More...
bool | checkMetaValue (const Feature &component, const String &meta_value_key, const double &meta_value_l, const double &meta_value_u, bool &key_exists) const
| Checks if the metaValue is within the user specified range. More...
std::map< String, int > | countLabelsAndTransitionTypes (const Feature &component_group, const TargetedExperiment &transitions)
| Count the number of heavy/light labels and quantifying/detecting/identifying transitions. More...
StringList | getUniqueSorted (const StringList &messages) const
| Sorts the messages and returns a copy without duplicates. More...
| MRMFeatureFilter ()
| Constructor. More...
| ~MRMFeatureFilter () override
| Destructor. More...
Public Member Functions inherited from DefaultParamHandler
| DefaultParamHandler (const String &name)
| Constructor with name that is displayed in error messages. More...
| DefaultParamHandler (const DefaultParamHandler &rhs)
| Copy constructor. More...
virtual | ~DefaultParamHandler ()
| Destructor. More...
virtual DefaultParamHandler & | operator= (const DefaultParamHandler &rhs)
| Assignment operator. More...
virtual bool | operator== (const DefaultParamHandler &rhs) const
| Equality operator. More...
void | setParameters (const Param &param)
| Sets the parameters. More...
const Param & | getParameters () const
| Non-mutable access to the parameters. More...
const Param & | getDefaults () const
| Non-mutable access to the default parameters. More...
const String & | getName () const
| Non-mutable access to the name. More...
void | setName (const String &name)
| Mutable access to the name. More...
const std::vector< String > & | getSubsections () const
| Non-mutable access to the registered subsections. More...

## Private Member Functions

template<typename T >
bool | checkRange (const T &value, const T &value_l, const T &value_u) const

## Private Attributes

String | flag_or_filter_
| flag or filter (i.e., remove) features that do not pass the QC More...
bool | report_xic_
| include the data points for the extracted ion chromatogram (XIC) in the attachment More...
bool | report_tic_
| include the data points for the total ion chromatogram (TIC) in the attachment More...
QcMLFile::Attachment | attachment_
| qcMLFile Attachment More...
FeatureMap | features_
| FeatureMap. More...
std::map< String, std::vector< QcMLFile::QualityParameter > > | component_group_qc_report_
| component group/peptide/compound QCs More...
std::map< String, std::vector< QcMLFile::QualityParameter > > | component_qc_report_
| component/transition QCs More...
std::map< std::vector< String >, std::vector< QcMLFile::QualityParameter > > | multi_component_group_qc_report_
| multi transition QCs More...

## Additional Inherited Members

Protected Member Functions inherited from DefaultParamHandler
void | defaultsToParam_ ()
| Updates the parameters after the defaults have been set in the constructor. More...
Protected Attributes inherited from DefaultParamHandler
Param | param_
| Container for current parameters. More...
Param | defaults_
| Container for default parameters. This member should be filled in the constructor of derived classes! More...
std::vector< String > | subsections_
| Container for registered subsections. This member should be filled in the constructor of derived classes! More...
String | error_name_
| Name that is displayed in error messages during the parameter checking. More...
bool | check_defaults_
| If this member is set to false no checking if parameters in done;. More...
bool | warn_empty_defaults_
| If this member is set to false no warning is emitted when defaults are empty;. More...

## Detailed Description

The MRMFeatureFilter either flags components and/or transitions that do not pass the QC criteria or filters out components and/or transitions that do not pass the QC criteria.

## Constructor & Destructor Documentation

## ◆ MRMFeatureFilter()

MRMFeatureFilter | ( |  | ) |

Constructor.

## ◆ ~MRMFeatureFilter()

~MRMFeatureFilter | ( |  | ) |

override

Destructor.

## Member Function Documentation

## ◆ calculateIonRatio()

double calculateIonRatio | ( | const Feature & | component_1,
|  | const Feature & | component_2,
|  | const String & | feature_name
| ) |  |

Calculates the ion ratio between two transitions.

Parameters

  component_1 | component of the numerator
  component_2 | component of the denominator
  feature_name | name of the feature to calculate the ratio on e.g., peak_apex, peak_area

Returns
  The ratio.

## ◆ calculateResolution()

double calculateResolution | ( | Feature & | component_1,
|  | Feature & | component_2
| ) |  |

Calculates the resolution between two features.

Parameters

  component_1 | component 1
  component_2 | component 2

Returns
  The difference.

## ◆ calculateRTDifference()

double calculateRTDifference | ( | Feature & | component_1,
|  | Feature & | component_2
| ) |  |

Calculates the retention time difference between two features.

Parameters

  component_1 | First eluting component
  component_2 | Second eluting component

Returns
  The difference.

## ◆ checkMetaValue()

bool checkMetaValue | ( | const Feature & | component,
|  | const String & | meta_value_key,
|  | const double & | meta_value_l,
|  | const double & | meta_value_u,
|  | bool & | key_exists
| ) |  | const

Checks if the metaValue is within the user specified range.

Parameters

  [in] | component | component of the numerator
  [in] | meta_value_key | Name of the metaValue
  [in] | meta_value_l | Lower bound (inclusive) for the metaValue range
  [in] | meta_value_u | Upper bound (inclusive) for the metaValue range
  [out] | key_exists | true if the given key is found, false otherwise

Returns
  True if the metaValue is within the bounds, and False otherwise.

## ◆ checkRange()

bool checkRange | ( | const T & | value,
|  | const T & | value_l,
|  | const T & | value_u
| ) |  | const

private

## ◆ countLabelsAndTransitionTypes()

std::map<String,int> countLabelsAndTransitionTypes | ( | const Feature & | component_group,
|  | const TargetedExperiment & | transitions
| ) |  |

Count the number of heavy/light labels and quantifying/detecting/identifying transitions.

Parameters

  component | component_group with subordinates
  transitions | transitions from a TargetedExperiment

Returns
  Map of labels/transition types and their corresponding number.

## ◆ FeatureMapToAttachment()

void FeatureMapToAttachment | ( | FeatureMap & | features,
|  | QcMLFile::Attachment & | attachment
| ) |  |

Converts a FeatureMap to a qcMLFile::Attachment.

Parameters

  features | FeatureMap to flag or filter
  attachment | qcML Attachment

## ◆ FilterFeatureMap()

void FilterFeatureMap | ( | FeatureMap & | features,
|  | const MRMFeatureQC & | filter_criteria,
|  | const TargetedExperiment & | transitions
| ) |  |

Flags or filters features and subordinates in a FeatureMap.

Parameters

  features | FeatureMap to flag or filter
  filter_criteria | MRMFeatureQC class defining QC parameters
  transitions | transitions from a TargetedExperiment

## ◆ getDefaultParameters()

void getDefaultParameters | ( | Param & | params | ) | const

Get the class' default parameters.

Parameters

  [out] | params | Output parameters

## ◆ getUniqueSorted()

StringList getUniqueSorted | ( | const StringList & | messages | ) | const

Sorts the messages and returns a copy without duplicates.

Parameters

  [in] | messages | A StringList containing the failure messages

Returns
  A copy of the input, without duplicates

## ◆ updateMembers_()

void updateMembers_ | ( |  | ) |

override virtual

Synchronize members with param class.

Reimplemented from DefaultParamHandler.

## Member Data Documentation

## ◆ attachment_

QcMLFile::Attachment attachment_

private

qcMLFile Attachment

## ◆ component_group_qc_report_

std::map<String,std::vector<QcMLFile::QualityParameter> > component_group_qc_report_

private

component group/peptide/compound QCs

## ◆ component_qc_report_

std::map<String,std::vector<QcMLFile::QualityParameter> > component_qc_report_

private

component/transition QCs

## ◆ features_

FeatureMap features_

private

FeatureMap.

## ◆ flag_or_filter_

String flag_or_filter_

private

flag or filter (i.e., remove) features that do not pass the QC

## ◆ multi_component_group_qc_report_

std::map<std::vector<String>,std::vector<QcMLFile::QualityParameter> > multi_component_group_qc_report_

private

multi transition QCs

## ◆ report_tic_

bool report_tic_

private

include the data points for the total ion chromatogram (TIC) in the attachment

## ◆ report_xic_

bool report_xic_

private

include the data points for the extracted ion chromatogram (XIC) in the attachment