OpenMS
Loading...
Searching...
No Matches
SwathMapMassCorrection.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
11#include <vector>
12
15
16namespace OpenMS
17{
18
26 class OPENMS_DLLAPI SwathMapMassCorrection :
28 {
29
30public:
31
33
35
37 ~SwathMapMassCorrection() override = default;
39
41 void updateMembers_() override;
42
59 void correctMZ(const std::map<String, OpenMS::MRMFeatureFinderScoring::MRMTransitionGroupType *>& transition_group_map,
60 const OpenSwath::LightTargetedExperiment & targeted_exp,
61 std::vector< OpenSwath::SwathMap > & swath_maps, const bool pasef);
62
78 void correctIM(const std::map<String, OpenMS::MRMFeatureFinderScoring::MRMTransitionGroupType *> & transition_group_map,
79 const OpenSwath::LightTargetedExperiment & targeted_exp,
80 const std::vector< OpenSwath::SwathMap > & swath_maps,
81 const bool pasef,
82 TransformationDescription & im_trafo);
83
94 std::vector<OpenSwath::SwathMap> findSwathMapsPasef(const OpenMS::MRMFeatureFinderScoring::MRMTransitionGroupType& transition_group,
95 const std::vector< OpenSwath::SwathMap > & swath_maps);
96
116 static double estimateWindow(
117 std::vector<double> residuals,
118 double quantile = 0.99,
119 bool full_width = true,
120 double padding_factor = 1.0
121 );
122
124 double getFragmentMzWindow() const;
125
127 void setFragmentMzWindow(double fragmentMzWindow);
128
130 double getFragmentImWindow() const;
131
133 void setFragmentImWindow(double fragmentImWindow);
134
136 double getPrecursorMzWindow() const;
137
139 void setPrecursorMzWindow(double precursorMzWindow);
140
142 double getPrecursorImWindow() const;
143
145 void setPrecursorImWindow(double precursorImWindow);
146
147 private:
156
158 double mz_estimation_padding_factor_ = 1.0;
159 double im_estimation_padding_factor_ = 1.0;
160 double fragment_mz_window_ = -1;
161 double fragment_im_window_ = -1;
162 double precursor_mz_window_ = -1;
163 double precursor_im_window_ = -1;
164 };
165}
166
A base class for all classes handling default parameters.
Definition DefaultParamHandler.h:66
The representation of a group of transitions in a targeted proteomics experiment.
Definition MRMTransitionGroup.h:42
A more convenient string class.
Definition String.h:34
A class containing correction functions for Swath MS maps.
Definition SwathMapMassCorrection.h:28
void setPrecursorImWindow(double precursorImWindow)
Set the estimated precursor ion mobility extraction window.
bool mz_extraction_window_ppm_
Definition SwathMapMassCorrection.h:149
void setFragmentMzWindow(double fragmentMzWindow)
Set the estimated fragment m/z extraction window (ppm_.
static double estimateWindow(std::vector< double > residuals, double quantile=0.99, bool full_width=true, double padding_factor=1.0)
Estimate an extraction window from absolute residuals.
double getPrecursorMzWindow() const
Retrieve the estimated precursor m/z extraction window (ppm)
double getFragmentMzWindow() const
Retrieve the estimated fragment m/z extraction window (ppm)
double getFragmentImWindow() const
Retrieve the estimated fragment ion mobility extraction window.
double im_extraction_window_
Definition SwathMapMassCorrection.h:151
void setFragmentImWindow(double fragmentImWindow)
Set the estimated fragment ion mobility extraction window.
String mz_correction_function_
Definition SwathMapMassCorrection.h:152
~SwathMapMassCorrection() override=default
Destructor.
String debug_mz_file_
Definition SwathMapMassCorrection.h:155
double mz_extraction_window_
Definition SwathMapMassCorrection.h:148
void correctIM(const std::map< String, OpenMS::MRMFeatureFinderScoring::MRMTransitionGroupType * > &transition_group_map, const OpenSwath::LightTargetedExperiment &targeted_exp, const std::vector< OpenSwath::SwathMap > &swath_maps, const bool pasef, TransformationDescription &im_trafo)
Correct the ion mobility values of a SWATH map based on the RT-normalization peptides.
bool ms1_im_
Definition SwathMapMassCorrection.h:150
String im_correction_function_
Definition SwathMapMassCorrection.h:153
void updateMembers_() override
Synchronize members with param class.
SwathMapMassCorrection()
Constructor.
String debug_im_file_
Definition SwathMapMassCorrection.h:154
std::vector< OpenSwath::SwathMap > findSwathMapsPasef(const OpenMS::MRMFeatureFinderScoring::MRMTransitionGroupType &transition_group, const std::vector< OpenSwath::SwathMap > &swath_maps)
Computes the SwathMaps for PASEF data in which windows can have the same m/z but differ by ion mobili...
double getPrecursorImWindow() const
Retrieve the estimated precursor ion mobility extraction window.
void setPrecursorMzWindow(double precursorMzWindow)
Set the estimated precursor m/z extraction window (ppm)
void correctMZ(const std::map< String, OpenMS::MRMFeatureFinderScoring::MRMTransitionGroupType * > &transition_group_map, const OpenSwath::LightTargetedExperiment &targeted_exp, std::vector< OpenSwath::SwathMap > &swath_maps, const bool pasef)
Correct the m/z values of a SWATH map based on the RT-normalization peptides.
Generic description of a coordinate transformation.
Definition TransformationDescription.h:37
Main OpenMS namespace.
Definition openswathalgo/include/OpenMS/OPENSWATHALGO/DATAACCESS/ISpectrumAccess.h:19
Definition TransitionExperiment.h:356