OpenMS  2.4.0
OpenSwathScores.h
Go to the documentation of this file.
1 // --------------------------------------------------------------------------
2 // OpenMS -- Open-Source Mass Spectrometry
3 // --------------------------------------------------------------------------
4 // Copyright The OpenMS Team -- Eberhard Karls University Tuebingen,
5 // ETH Zurich, and Freie Universitaet Berlin 2002-2018.
6 //
7 // This software is released under a three-clause BSD license:
8 // * Redistributions of source code must retain the above copyright
9 // notice, this list of conditions and the following disclaimer.
10 // * Redistributions in binary form must reproduce the above copyright
11 // notice, this list of conditions and the following disclaimer in the
12 // documentation and/or other materials provided with the distribution.
13 // * Neither the name of any author or any participating institution
14 // may be used to endorse or promote products derived from this software
15 // without specific prior written permission.
16 // For a full list of authors, refer to the file AUTHORS.
17 // --------------------------------------------------------------------------
18 // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
19 // AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
20 // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
21 // ARE DISCLAIMED. IN NO EVENT SHALL ANY OF THE AUTHORS OR THE CONTRIBUTING
22 // INSTITUTIONS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
23 // EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
24 // PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
25 // OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
26 // WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
27 // OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
28 // ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
29 //
30 // --------------------------------------------------------------------------
31 // $Maintainer: Hannes Roest $
32 // $Authors: Hannes Roest $
33 // --------------------------------------------------------------------------
34 
35 #pragma once
36 
37 #include <OpenMS/OpenMSConfig.h>
38 #include <OpenMS/CONCEPT/Types.h>
39 
40 #include <string>
41 
42 namespace OpenMS
43 {
44 
49  struct OPENMS_DLLAPI OpenSwath_Scores_Usage
50  {
51  bool use_coelution_score_ = true;
52  bool use_shape_score_ = true;
53  bool use_rt_score_ = true;
54  bool use_library_score_ = true;
55  bool use_elution_model_score_ = true;
56  bool use_intensity_score_ = true;
57  bool use_total_xic_score_ = true;
58  bool use_total_mi_score_ = true;
59  bool use_nr_peaks_score_ = true;
60  bool use_sn_score_ = true;
61  bool use_mi_score_ = true;
62  bool use_dia_scores_ = true;
63  bool use_sonar_scores = true;
64  bool use_ms1_correlation = true;
65  bool use_ms1_fullscan = true;
66  bool use_ms1_mi = true;
67  bool use_uis_scores = true;
68  };
69 
78  struct OPENMS_DLLAPI OpenSwath_Scores
79  {
80  double elution_model_fit_score = 0;
81  double library_corr = 0;
82  double library_norm_manhattan = 0;
83  double library_rootmeansquare = 0;
84  double library_sangle = 0;
85  double norm_rt_score = 0;
86 
87  double isotope_correlation = 0;
88  double isotope_overlap = 0;
89  double massdev_score = 0;
90  double xcorr_coelution_score = 0;
91  double xcorr_shape_score = 0;
92 
93  double yseries_score = 0;
94  double bseries_score = 0;
95  double log_sn_score = 0;
96 
97  double weighted_coelution_score = 0;
98  double weighted_xcorr_shape = 0;
99  double weighted_massdev_score = 0;
100 
101  double ms1_xcorr_coelution_score = -1;
102  double ms1_xcorr_coelution_contrast_score = 0;
103  double ms1_xcorr_coelution_combined_score = 0;
104  double ms1_xcorr_shape_score = -1;
105  double ms1_xcorr_shape_contrast_score = 0;
106  double ms1_xcorr_shape_combined_score = 0;
107  double ms1_ppm_score = 0;
108  double ms1_isotope_correlation = 0;
109  double ms1_isotope_overlap = 0;
110  double ms1_mi_score = -1;
111  double ms1_mi_contrast_score = 0;
112  double ms1_mi_combined_score = 0;
113 
114  double sonar_sn = 0;
115  double sonar_diff = 0;
116  double sonar_trend = 0;
117  double sonar_rsq = 0;
118  double sonar_shape = 0;
119  double sonar_lag = 0;
120 
121  double library_manhattan = 0;
122  double library_dotprod = 0;
123  double intensity = 0;
124  double total_xic = 0;
125  double nr_peaks = 0;
126  double sn_ratio = 0;
127  double mi_score = 0;
128  double weighted_mi_score = 0;
129 
130  double rt_difference = 0;
131  double normalized_experimental_rt = 0;
132  double raw_rt_score = 0;
133 
134  double dotprod_score_dia = 0;
135  double manhatt_score_dia = 0;
136 
137  OpenSwath_Scores() = default;
138 
139  double get_quick_lda_score(double library_corr_,
140  double library_norm_manhattan_,
141  double norm_rt_score_,
142  double xcorr_coelution_score_,
143  double xcorr_shape_score_,
144  double log_sn_score_) const;
145 
156  double calculate_lda_prescore(const OpenSwath_Scores& scores) const;
157 
166  double calculate_lda_single_transition(const OpenSwath_Scores& scores) const;
167 
175  double calculate_swath_lda_prescore(const OpenSwath_Scores& scores) const;
176 
177  };
178 
179  struct OPENMS_DLLAPI OpenSwath_Ind_Scores
180  {
181  int ind_num_transitions = 0;
182  std::string ind_isotope_correlation = "";
183  std::string ind_isotope_overlap = "";
184  std::string ind_massdev_score = "";
185  std::string ind_xcorr_coelution_score = "";
186  std::string ind_xcorr_shape_score = "";
187  std::string ind_log_sn_score = "";
188  std::string ind_transition_names = "";
189  std::string ind_area_intensity = "";
190  std::string ind_total_area_intensity = "";
191  std::string ind_intensity_score = "";
192  std::string ind_apex_intensity = "";
193  std::string ind_total_mi = "";
194  std::string ind_log_intensity = "";
195  std::string ind_intensity_ratio = "";
196  std::string ind_mi_ratio = "";
197  std::string ind_mi_score = "";
198 
199  OpenSwath_Ind_Scores() = default;
200 
201  };
202 
203 }
204 
205 
Main OpenMS namespace.
Definition: FeatureDeconvolution.h:46
Definition: OpenSwathScores.h:179
A structure to store which scores should be used by the OpenSWATH Algorithm.
Definition: OpenSwathScores.h:49
A structure to hold the different scores computed by OpenSWATH.
Definition: OpenSwathScores.h:78