OpenMS  2.4.0
MzTab.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: Timo Sachsenberg $
32 // $Authors: Timo Sachsenberg $
33 // --------------------------------------------------------------------------
34 
35 #pragma once
36 
44 
45 #include <map>
46 #include <vector>
47 #include <list>
48 #include <algorithm>
49 
50 #pragma clang diagnostic push
51 #pragma clang diagnostic ignored "-Wnon-virtual-dtor"
52 
53 namespace OpenMS
54 {
62 // MzTab supports null, NaN, Inf for cells with Integer or Double values. MzTabCellType explicitly defines the state of the cell for these types.
64  {
70  };
71 
72 // basic interface for all MzTab datatypes (can be null; are converted from and to cell string)
73  class OPENMS_DLLAPI MzTabNullAbleInterface
74  {
75 public:
76  virtual ~MzTabNullAbleInterface();
77  virtual bool isNull() const = 0;
78  virtual void setNull(bool b) = 0;
79  virtual String toCellString() const = 0;
80  virtual void fromCellString(const String&) = 0;
81  };
82 
83 // interface for NaN- and Inf- able datatypes (Double and Integer in MzTab). These are as well null-able
84  class OPENMS_DLLAPI MzTabNullNaNAndInfAbleInterface :
86  {
87 public:
89  virtual bool isNaN() const = 0;
90  virtual void setNaN() = 0;
91  virtual bool isInf() const = 0;
92  virtual void setInf() = 0;
93  };
94 
95 // base class for atomic, non-container types (Double, Int)
96  class OPENMS_DLLAPI MzTabNullAbleBase :
98  {
99 public:
101 
102  ~MzTabNullAbleBase() override;
103 
104  bool isNull() const override;
105 
106  void setNull(bool b) override;
107 
108 protected:
109  bool null_;
110  };
111 
112 // base class for the atomic non-container like MzTab data types (Double, Int)
113  class OPENMS_DLLAPI MzTabNullNaNAndInfAbleBase :
115  {
116 public:
118 
119  ~MzTabNullNaNAndInfAbleBase() override;
120 
121  bool isNull() const override;
122 
123  void setNull(bool b) override;
124 
125  bool isNaN() const override;
126 
127  void setNaN() override;
128 
129  bool isInf() const override;
130 
131  void setInf() override;
132 
133 protected:
135  };
136 
137  class OPENMS_DLLAPI MzTabDouble :
139  {
140 public:
141  MzTabDouble();
142 
143  explicit MzTabDouble(const double v);
144 
145  ~MzTabDouble() override;
146 
147  void set(const double& value);
148 
149  double get() const;
150 
151  String toCellString() const override;
152 
153  void fromCellString(const String& s) override;
154 
155 protected:
156  double value_;
157  };
158 
159  class OPENMS_DLLAPI MzTabDoubleList :
160  public MzTabNullAbleBase
161  {
162 public:
163  MzTabDoubleList();
164 
165  ~MzTabDoubleList() override;
166 
167  bool isNull() const override;
168 
169  void setNull(bool b) override;
170 
171  String toCellString() const override;
172 
173  void fromCellString(const String& s) override;
174 
175  std::vector<MzTabDouble> get() const;
176 
177  void set(const std::vector<MzTabDouble>& entries);
178 
179 protected:
180  std::vector<MzTabDouble> entries_;
181  };
182 
183  class OPENMS_DLLAPI MzTabInteger :
185  {
186 public:
187  MzTabInteger();
188 
189  explicit MzTabInteger(const int v);
190 
191  ~MzTabInteger() override;
192 
193  void set(const Int& value);
194 
195  Int get() const;
196 
197  String toCellString() const override;
198 
199  void fromCellString(const String& s) override;
200 
201 protected:
203  };
204 
205  class OPENMS_DLLAPI MzTabIntegerList :
206  public MzTabNullAbleBase
207  {
208 public:
210 
211  bool isNull() const override;
212 
213  void setNull(bool b) override;
214 
215  String toCellString() const override;
216 
217  void fromCellString(const String& s) override;
218 
219  std::vector<MzTabInteger> get() const;
220 
221  void set(const std::vector<MzTabInteger>& entries);
222 
223 protected:
224  std::vector<MzTabInteger> entries_;
225  };
226 
227  class OPENMS_DLLAPI MzTabBoolean :
228  public MzTabNullAbleBase
229  {
230 public:
231  MzTabBoolean();
232 
233  explicit MzTabBoolean(bool v);
234 
235  ~MzTabBoolean() override;
236 
237  void set(const bool& value);
238 
239  Int get() const;
240 
241  String toCellString() const override;
242 
243  void fromCellString(const String& s) override;
244 
245 protected:
246  bool value_;
247  };
248 
249  class OPENMS_DLLAPI MzTabString :
251  {
252 public:
253  MzTabString();
254 
255  explicit MzTabString(const String& s);
256 
257  ~MzTabString() override;
258 
259  void set(const String& value);
260 
261  String get() const;
262 
263  bool isNull() const override;
264 
265  void setNull(bool b) override;
266 
267  String toCellString() const override;
268 
269  void fromCellString(const String& s) override;
270 
271 protected:
273  };
274 
275  class OPENMS_DLLAPI MzTabParameter :
277  {
278 public:
279  MzTabParameter();
280 
281  ~MzTabParameter() override;
282 
283  bool isNull() const override;
284 
285  void setNull(bool b) override;
286 
287  void setCVLabel(const String& CV_label);
288 
289  void setAccession(const String& accession);
290 
291  void setName(const String& name);
292 
293  void setValue(const String& value);
294 
295  String getCVLabel() const;
296 
297  String getAccession() const;
298 
299  String getName() const;
300 
301  String getValue() const;
302 
303  String toCellString() const override;
304 
305  void fromCellString(const String& s) override;
306 
307 protected:
312  };
313 
314  class OPENMS_DLLAPI MzTabParameterList :
316  {
317 public:
318 
319  ~MzTabParameterList() override;
320 
321  bool isNull() const override;
322 
323  void setNull(bool b) override;
324 
325  String toCellString() const override;
326 
327  void fromCellString(const String& s) override;
328 
329  std::vector<MzTabParameter> get() const;
330 
331  void set(const std::vector<MzTabParameter>& parameters);
332 
333 protected:
334  std::vector<MzTabParameter> parameters_;
335  };
336 
337  class OPENMS_DLLAPI MzTabStringList :
339  {
340 public:
341  MzTabStringList();
342 
343  ~MzTabStringList() override;
344 
345  // needed for e.g. ambiguity_members and GO accessions as these use ',' as separator while the others use '|'
346  void setSeparator(char sep);
347 
348  bool isNull() const override;
349 
350  void setNull(bool b) override;
351 
352  String toCellString() const override;
353 
354  void fromCellString(const String& s) override;
355 
356  std::vector<MzTabString> get() const;
357 
358  void set(const std::vector<MzTabString>& entries);
359 
360 protected:
361  std::vector<MzTabString> entries_;
362  char sep_;
363  };
364 
365  class OPENMS_DLLAPI MzTabModification :
367  {
368 public:
370 
371  ~MzTabModification() override;
372 
373  bool isNull() const override;
374 
375  void setNull(bool b) override;
376 
377  // set (potentially ambiguous) position(s) with associated parameter (might be null if not set)
378  void setPositionsAndParameters(const std::vector<std::pair<Size, MzTabParameter> >& ppp);
379 
380  std::vector<std::pair<Size, MzTabParameter> > getPositionsAndParameters() const;
381 
382  void setModificationIdentifier(const MzTabString& mod_id);
383 
384  MzTabString getModOrSubstIdentifier() const;
385 
386  String toCellString() const override;
387 
388  void fromCellString(const String& s) override;
389 
390 protected:
391  std::vector<std::pair<Size, MzTabParameter> > pos_param_pairs_;
393  };
394 
395  class OPENMS_DLLAPI MzTabModificationList :
396  public MzTabNullAbleBase
397  {
398 public:
399  ~MzTabModificationList() override;
400 
401  bool isNull() const override;
402 
403  void setNull(bool b) override;
404 
405  String toCellString() const override;
406 
407  void fromCellString(const String& s) override;
408 
409  std::vector<MzTabModification> get() const;
410 
411  void set(const std::vector<MzTabModification>& entries);
412 
413 protected:
414  std::vector<MzTabModification> entries_;
415 
416  };
417 
418  class OPENMS_DLLAPI MzTabSpectraRef :
420  {
421 public:
422  MzTabSpectraRef();
423 
424  ~MzTabSpectraRef() override;
425 
426  bool isNull() const override;
427 
428  void setNull(bool b) override;
429 
430  void setMSFile(Size index);
431 
432  void setSpecRef(String spec_ref);
433 
434  String getSpecRef() const;
435 
436  Size getMSFile() const;
437 
438  void setSpecRefFile(const String& spec_ref);
439 
440  String toCellString() const override;
441 
442  void fromCellString(const String& s) override;
443 
444 protected:
445  Size ms_run_; // number is specified in the meta data section.
447  };
448 
449 // MTD
450 
451  struct OPENMS_DLLAPI MzTabSampleMetaData
452  {
454  std::map<Size, MzTabParameter> species;
455  std::map<Size, MzTabParameter> tissue;
456  std::map<Size, MzTabParameter> cell_type;
457  std::map<Size, MzTabParameter> disease;
458  std::map<Size, MzTabParameter> custom;
459  };
460 
461  struct OPENMS_DLLAPI MzTabSoftwareMetaData
462  {
464  std::map<Size, MzTabString> setting;
465  };
466 
467  struct OPENMS_DLLAPI MzTabModificationMetaData
468  {
472  };
473 
474  struct OPENMS_DLLAPI MzTabAssayMetaData
475  {
477  std::map<Size, MzTabModificationMetaData> quantification_mod;
479  std::vector<int> ms_run_ref; // adapted to address https://github.com/HUPO-PSI/mzTab/issues/26
480  };
481 
482  struct OPENMS_DLLAPI MzTabCVMetaData
483  {
488  };
489 
490  struct OPENMS_DLLAPI MzTabInstrumentMetaData
491  {
494  std::map<Size, MzTabParameter> analyzer;
496  };
497 
498  struct OPENMS_DLLAPI MzTabContactMetaData
499  {
503  };
504 
505  struct OPENMS_DLLAPI MzTabMSRunMetaData
506  {
511  };
512 
513  struct OPENMS_DLLAPI MzTabStudyVariableMetaData
514  {
515  std::vector<int> assay_refs;
516  std::vector<int> sample_refs;
518  };
519 
520 // all meta data of a mzTab file. Please refer to specification for documentation.
521  class OPENMS_DLLAPI MzTabMetaData
522  {
523 public:
524  MzTabMetaData();
525 
532 
533  std::map<Size, MzTabParameter> protein_search_engine_score;
534  std::map<Size, MzTabParameter> peptide_search_engine_score;
535  std::map<Size, MzTabParameter> psm_search_engine_score;
536  std::map<Size, MzTabParameter> smallmolecule_search_engine_score;
537 
538  std::map<Size, MzTabParameterList> sample_processing;
539 
540  std::map<Size, MzTabInstrumentMetaData> instrument;
541 
542  std::map<Size, MzTabSoftwareMetaData> software;
543 
545 
546  std::map<Size, MzTabString> publication;
547 
548  std::map<Size, MzTabContactMetaData> contact;
549 
550  std::map<Size, MzTabString> uri;
551 
552  std::map<Size, MzTabModificationMetaData> fixed_mod;
553 
554  std::map<Size, MzTabModificationMetaData> variable_mod;
555 
557 
561 
562  std::map<Size, MzTabMSRunMetaData> ms_run;
563 
564  std::map<Size, MzTabParameter> custom;
565 
566  std::map<Size, MzTabSampleMetaData> sample;
567 
568  std::map<Size, MzTabAssayMetaData> assay;
569 
570  std::map<Size, MzTabStudyVariableMetaData> study_variable;
571 
572  std::map<Size, MzTabCVMetaData> cv;
573 
574  std::vector<String> colunit_protein;
575  std::vector<String> colunit_peptide;
576  std::vector<String> colunit_psm;
577  std::vector<String> colunit_small_molecule;
578  };
579 
580  typedef std::pair<String, MzTabString> MzTabOptionalColumnEntry; // column name (not null able), value (null able)
581 
582 // PRT - Protein section (Table based)
583  struct OPENMS_DLLAPI MzTabProteinSectionRow
584  {
586  MzTabString accession; // The protein’s accession.
587  MzTabString description; // Human readable description (i.e. the name)
588  MzTabInteger taxid; // NEWT taxonomy for the species.
589  MzTabString species; // Human readable name of the species
590  MzTabString database; // Name of the protein database.
591  MzTabString database_version; // String Version of the protein database.
592  MzTabParameterList search_engine; // Search engine(s) identifying the protein.
593  std::map<Size, MzTabDouble> best_search_engine_score; // best_search_engine_score[1-n]
594  std::map<Size, std::map<Size, MzTabDouble> > search_engine_score_ms_run; // search_engine_score[index1]_ms_run[index2]
596  std::map<Size, MzTabInteger> num_psms_ms_run;
597  std::map<Size, MzTabInteger> num_peptides_distinct_ms_run;
598  std::map<Size, MzTabInteger> num_peptides_unique_ms_run;
599  MzTabStringList ambiguity_members; // Alternative protein identifications.
600  MzTabModificationList modifications; // Modifications identified in the protein.
601  MzTabString uri; // Location of the protein’s source entry.
602  MzTabStringList go_terms; // List of GO terms for the protein.
603  MzTabDouble protein_coverage; // (0-1) Amount of protein sequence identified.
604  std::map<Size, MzTabDouble> protein_abundance_assay;
605  std::map<Size, MzTabDouble> protein_abundance_study_variable;
606  std::map<Size, MzTabDouble> protein_abundance_stdev_study_variable;
607  std::map<Size, MzTabDouble> protein_abundance_std_error_study_variable;
608  std::vector<MzTabOptionalColumnEntry> opt_; // Optional Columns must start with “opt_”
609  };
610 
611 // PEP - Peptide section (Table based)
612  struct OPENMS_DLLAPI MzTabPeptideSectionRow
613  {
614  MzTabString sequence; // The peptide’s sequence.
615  MzTabString accession; // The protein’s accession.
616  MzTabBoolean unique; // 0=false, 1=true, null else: Peptide is unique for the protein.
617  MzTabString database; // Name of the sequence database.
618  MzTabString database_version; // Version (and optionally # of entries).
619  MzTabParameterList search_engine; // Search engine(s) that identified the peptide.
620  std::map<Size, MzTabDouble> best_search_engine_score; // Search engine(s) score(s) for the peptide.
621  std::map<Size, std::map<Size, MzTabDouble> > search_engine_score_ms_run;
622  MzTabInteger reliability; // (1-3) 0=null Identification reliability for the peptide.
623  MzTabModificationList modifications; // Modifications identified in the peptide.
624  MzTabDoubleList retention_time; // Time points in seconds. Semantics may vary.
626  MzTabInteger charge; // Precursor ion’s charge.
627  MzTabDouble mass_to_charge; // Precursor ion’s m/z.
628  MzTabString uri; // Location of the PSMs source entry.
629  MzTabSpectraRef spectra_ref; // Spectra identifying the peptide.
630  std::map<Size, MzTabDouble> peptide_abundance_assay;
631  std::map<Size, MzTabDouble> peptide_abundance_study_variable;
632  std::map<Size, MzTabDouble> peptide_abundance_stdev_study_variable;
633  std::map<Size, MzTabDouble> peptide_abundance_std_error_study_variable;
634  std::vector<MzTabOptionalColumnEntry> opt_; // Optional columns must start with “opt_”.
635  };
636 
637 // PSM - PSM section (Table based)
638  struct OPENMS_DLLAPI MzTabPSMSectionRow
639  {
640  MzTabString sequence; // The peptide’s sequence.
642  MzTabString accession; // The protein’s accession.
643  MzTabBoolean unique; // 0=false, 1=true, null else: Peptide is unique for the protein.
644  MzTabString database; // Name of the sequence database.
645  MzTabString database_version; // Version (and optionally # of entries).
646  MzTabParameterList search_engine; // Search engine(s) that identified the peptide.
647  std::map<Size, MzTabDouble> search_engine_score; // Search engine(s) score(s) for the peptide.
648  MzTabInteger reliability; // (1-3) 0=null Identification reliability for the peptide.
649  MzTabModificationList modifications; // Modifications identified in the peptide.
650  MzTabDoubleList retention_time; // Time points in seconds. Semantics may vary.
651  MzTabInteger charge; // The charge of the experimental precursor ion.
652  MzTabDouble exp_mass_to_charge; // The m/z ratio of the experimental precursor ion.
654  MzTabString uri; // Location of the PSM’s source entry.
655  MzTabSpectraRef spectra_ref; // Spectra identifying the peptide.
660  std::vector<MzTabOptionalColumnEntry> opt_; // Optional columns must start with “opt_”.
661  };
662 
663 // SML Small molecule section (table based)
664  struct OPENMS_DLLAPI MzTabSmallMoleculeSectionRow
665  {
666  MzTabStringList identifier; // The small molecule’s identifier.
667  MzTabString chemical_formula; // Chemical formula of the identified compound.
668  MzTabString smiles; // Molecular structure in SMILES format.
669  MzTabString inchi_key; // InChi Key of the identified compound.
670  MzTabString description; // Human readable description (i.e. the name)
671  MzTabDouble exp_mass_to_charge; // Precursor ion’s m/z.
672  MzTabDouble calc_mass_to_charge; // Precursor ion’s m/z.
673  MzTabDouble charge; // Precursor ion’s charge.
674  MzTabDoubleList retention_time; // Time points in seconds. Semantics may vary.
675  MzTabInteger taxid; // NEWT taxonomy for the species.
676  MzTabString species; // Human readable name of the species
677  MzTabString database; // Name of the used database.
678  MzTabString database_version; // String Version of the database (and optionally # of compounds).
679  MzTabInteger reliability; // (1-3) The identification reliability.
680  MzTabString uri; // The source entry’s location.
681  MzTabSpectraRef spectra_ref; // Spectra identifying the small molecule.
682  MzTabParameterList search_engine; // Search engine(s) identifying the small molecule.
683  std::map<Size, MzTabDouble> best_search_engine_score; // Search engine(s) identifications score(s).
684  std::map<Size, std::map<Size, MzTabDouble> > search_engine_score_ms_run;
685  MzTabString modifications; // Modifications identified on the small molecule.
686  std::map<Size, MzTabDouble> smallmolecule_abundance_assay;
687  std::map<Size, MzTabDouble> smallmolecule_abundance_study_variable;
688  std::map<Size, MzTabDouble> smallmolecule_abundance_stdev_study_variable;
690  std::vector<MzTabOptionalColumnEntry> opt_; // Optional columns must start with “opt_”.
691  };
692 
693  typedef std::vector<MzTabProteinSectionRow> MzTabProteinSectionRows;
694  typedef std::vector<MzTabPeptideSectionRow> MzTabPeptideSectionRows;
695  typedef std::vector<MzTabPSMSectionRow> MzTabPSMSectionRows;
696  typedef std::vector<MzTabSmallMoleculeSectionRow> MzTabSmallMoleculeSectionRows;
697 
704  class OPENMS_DLLAPI MzTab
705  {
706 public:
708  MzTab();
709 
711  virtual ~MzTab();
712 
713  const MzTabMetaData& getMetaData() const;
714 
715  void setMetaData(const MzTabMetaData& md);
716 
717  const MzTabProteinSectionRows& getProteinSectionRows() const;
718 
719  void setProteinSectionRows(const MzTabProteinSectionRows& psd);
720 
721  const MzTabPeptideSectionRows& getPeptideSectionRows() const;
722 
723  void setPeptideSectionRows(const MzTabPeptideSectionRows& psd);
724 
725  const MzTabPSMSectionRows& getPSMSectionRows() const;
726 
727  void setPSMSectionRows(const MzTabPSMSectionRows& psd);
728 
729  void setCommentRows(const std::map<Size, String>& com);
730 
731  void setEmptyRows(const std::vector<Size>& empty);
732 
733  const std::vector<Size>& getEmptyRows() const;
734 
735  const std::map<Size, String>& getCommentRows() const;
736 
737  const MzTabSmallMoleculeSectionRows& getSmallMoleculeSectionRows() const;
738 
739  void setSmallMoleculeSectionRows(const MzTabSmallMoleculeSectionRows& smsd);
740 
741  // Extract opt_ (custom, optional column names)
742  std::vector<String> getProteinOptionalColumnNames() const;
743 
744  // Extract opt_ (custom, optional column names)
745  std::vector<String> getPeptideOptionalColumnNames() const;
746 
747  // Extract opt_ (custom, optional column names)
748  std::vector<String> getPSMOptionalColumnNames() const;
749 
750  // Extract opt_ (custom, optional column names)
751  std::vector<String> getSmallMoleculeOptionalColumnNames() const;
752 
760  static void addPepEvidenceToRows(const std::vector<PeptideEvidence>& peptide_evidences, MzTabPSMSectionRow& row, MzTabPSMSectionRows& rows);
761 
762  static void addMetaInfoToOptionalColumns(const std::set<String>& keys, std::vector<MzTabOptionalColumnEntry>& opt, const String id, const MetaInfoInterface meta);
763 
764  static std::map<Size, MzTabModificationMetaData> generateMzTabStringFromModifications(const std::vector<String>& mods);
765 
766  static std::map<Size, MzTabModificationMetaData> generateMzTabStringFromVariableModifications(const std::vector<String>& mods);
767 
768  static std::map<Size, MzTabModificationMetaData> generateMzTabStringFromFixedModifications(const std::vector<String>& mods);
769 
770  static MzTab exportFeatureMapToMzTab(const FeatureMap& feature_map, const String& filename);
771 
772  static MzTab exportIdentificationsToMzTab(const std::vector<ProteinIdentification>& prot_ids, const std::vector<PeptideIdentification>& peptide_ids, const String& filename);
773 
774  // Generate MzTab style list of PTMs from AASequence object.
775  // All passed fixed modifications are not reported (as suggested by the standard for the PRT and PEP section).
776  // In contrast, all modifications are reported in the PSM section (see standard document for details).
777  static MzTabModificationList extractModificationListFromAASequence(const AASequence& aas, const std::vector<String>& fixed_mods = std::vector<String>());
778 
779  static MzTab exportConsensusMapToMzTab(
780  const ConsensusMap & consensus_map,
781  const String & filename,
782  const bool export_unidentified_features,
783  const bool export_unassigned_ids,
784  String title = "ConsensusMap export from OpenMS");
785 
786 protected:
792  std::vector<Size> empty_rows_; // index of empty rows
793  std::map<Size, String> comment_rows_; // comments
794  };
795 
796 } // namespace OpenMS
797 
798 #pragma clang diagnostic pop
799 
std::map< Size, MzTabParameter > protein_search_engine_score
Definition: MzTab.h:533
Definition: MzTab.h:467
MzTabSpectraRef spectra_ref
Definition: MzTab.h:629
MzTabSpectraRef spectra_ref
Definition: MzTab.h:681
MzTabDoubleList retention_time
Definition: MzTab.h:650
MzTabString uri
Definition: MzTab.h:601
MzTabParameter quantification_reagent
Definition: MzTab.h:476
std::map< Size, MzTabString > setting
Definition: MzTab.h:464
std::vector< String > colunit_protein
Definition: MzTab.h:574
std::map< Size, MzTabStudyVariableMetaData > study_variable
Definition: MzTab.h:570
std::map< Size, MzTabModificationMetaData > variable_mod
Definition: MzTab.h:554
std::map< Size, MzTabDouble > protein_abundance_assay
Definition: MzTab.h:604
MzTabMetaData meta_data_
Definition: MzTab.h:787
MzTabString database
Definition: MzTab.h:617
A more convenient string class.
Definition: String.h:58
MzTabString position
Definition: MzTab.h:471
std::map< Size, MzTabAssayMetaData > assay
Definition: MzTab.h:568
MzTabString accession
Definition: MzTab.h:615
MzTabDouble calc_mass_to_charge
Definition: MzTab.h:672
MzTabString sequence
Definition: MzTab.h:614
std::map< Size, std::map< Size, MzTabDouble > > search_engine_score_ms_run
Definition: MzTab.h:621
Definition: MzTab.h:583
MzTabString sequence
Definition: MzTab.h:640
MzTabParameterList false_discovery_rate
Definition: MzTab.h:544
MzTabParameterList search_engine
Definition: MzTab.h:592
std::vector< String > colunit_small_molecule
Definition: MzTab.h:577
Definition: MzTab.h:69
MzTabString title
Definition: MzTab.h:530
std::vector< MzTabOptionalColumnEntry > opt_
Definition: MzTab.h:660
MzTabString sample_ref
Definition: MzTab.h:478
Definition: MzTab.h:113
std::map< Size, MzTabDouble > best_search_engine_score
Definition: MzTab.h:683
Definition: MzTab.h:67
MzTabString inchi_key
Definition: MzTab.h:669
Definition: MzTab.h:418
Definition: MzTab.h:482
Definition: MzTab.h:249
std::map< Size, MzTabParameter > tissue
Definition: MzTab.h:455
std::map< Size, MzTabParameter > custom
Definition: MzTab.h:564
MzTabString database
Definition: MzTab.h:644
Definition: MzTab.h:275
MzTabParameter source
Definition: MzTab.h:493
A container for features.
Definition: FeatureMap.h:93
MzTabString post
Definition: MzTab.h:657
std::vector< MzTabOptionalColumnEntry > opt_
Definition: MzTab.h:634
MzTabString end
Definition: MzTab.h:659
std::map< Size, MzTabParameter > cell_type
Definition: MzTab.h:456
MzTabString database
Definition: MzTab.h:590
std::map< Size, MzTabParameter > disease
Definition: MzTab.h:457
MzTabString mz_tab_id
Definition: MzTab.h:529
MzTabString full_name
Definition: MzTab.h:485
Size ms_run_
Definition: MzTab.h:445
String value_
Definition: MzTab.h:272
std::vector< String > colunit_psm
Definition: MzTab.h:576
MzTabString modifications
Definition: MzTab.h:685
MzTabString mz_tab_version
Definition: MzTab.h:526
MzTabString database_version
Definition: MzTab.h:591
String CV_label_
Definition: MzTab.h:308
MzTabParameterList search_engine
Definition: MzTab.h:619
A container for consensus elements.
Definition: ConsensusMap.h:75
Definition: MzTab.h:498
MzTabStringList identifier
Definition: MzTab.h:666
std::map< Size, MzTabModificationMetaData > fixed_mod
Definition: MzTab.h:552
std::map< Size, MzTabDouble > best_search_engine_score
Definition: MzTab.h:620
std::vector< MzTabSmallMoleculeSectionRow > MzTabSmallMoleculeSectionRows
Definition: MzTab.h:696
MzTabParameter name
Definition: MzTab.h:492
Definition: MzTab.h:474
Representation of a peptide/protein sequence.
Definition: AASequence.h:107
std::map< Size, MzTabDouble > protein_abundance_stdev_study_variable
Definition: MzTab.h:606
std::vector< MzTabModification > entries_
Definition: MzTab.h:414
MzTabCellStateType state_
Definition: MzTab.h:134
MzTabString affiliation
Definition: MzTab.h:501
std::vector< int > assay_refs
Definition: MzTab.h:515
Definition: MzTab.h:314
std::map< Size, MzTabParameter > psm_search_engine_score
Definition: MzTab.h:535
std::vector< MzTabOptionalColumnEntry > opt_
Definition: MzTab.h:690
Main OpenMS namespace.
Definition: FeatureDeconvolution.h:46
std::map< Size, MzTabDouble > peptide_abundance_study_variable
Definition: MzTab.h:631
MzTabString name
Definition: MzTab.h:500
char sep_
Definition: MzTab.h:362
Definition: MzTab.h:490
Int value_
Definition: MzTab.h:202
std::map< Size, MzTabParameter > species
Definition: MzTab.h:454
std::map< Size, MzTabDouble > protein_abundance_std_error_study_variable
Definition: MzTab.h:607
std::map< Size, MzTabDouble > smallmolecule_abundance_assay
Definition: MzTab.h:686
MzTabString uri
Definition: MzTab.h:680
std::vector< MzTabProteinSectionRow > MzTabProteinSectionRows
Definition: MzTab.h:693
MzTabDoubleList retention_time
Definition: MzTab.h:674
std::map< Size, MzTabDouble > peptide_abundance_stdev_study_variable
Definition: MzTab.h:632
MzTabBoolean unique
Definition: MzTab.h:616
double value_
Definition: MzTab.h:156
MzTabInteger reliability
Definition: MzTab.h:622
std::map< Size, MzTabCVMetaData > cv
Definition: MzTab.h:572
MzTabModificationList modifications
Definition: MzTab.h:649
std::map< Size, MzTabSampleMetaData > sample
Definition: MzTab.h:566
MzTabCellStateType
Data model of MzTab files. Please see the official MzTab specification at https://code.google.com/p/mztab/.
Definition: MzTab.h:63
std::vector< MzTabInteger > entries_
Definition: MzTab.h:224
Definition: MzTab.h:227
MzTabString description
Definition: MzTab.h:670
MzTabString accession
Definition: MzTab.h:586
std::map< Size, MzTabInteger > num_peptides_distinct_ms_run
Definition: MzTab.h:597
MzTabString accession
Definition: MzTab.h:642
std::map< Size, MzTabString > uri
Definition: MzTab.h:550
MzTabParameterList fragmentation_method
Definition: MzTab.h:510
MzTabString description
Definition: MzTab.h:453
MzTabParameter quantification_method
Definition: MzTab.h:556
MzTabModificationList modifications
Definition: MzTab.h:600
MzTabDouble mass_to_charge
Definition: MzTab.h:627
String accession_
Definition: MzTab.h:309
std::map< Size, MzTabDouble > peptide_abundance_assay
Definition: MzTab.h:630
MzTabString species
Definition: MzTab.h:676
MzTabString uri
Definition: MzTab.h:654
Definition: MzTab.h:337
MzTabPeptideSectionRows peptide_data_
Definition: MzTab.h:789
MzTabProteinSectionRows protein_data_
Definition: MzTab.h:788
Definition: MzTab.h:521
std::map< Size, MzTabString > publication
Definition: MzTab.h:546
String spec_ref_
Definition: MzTab.h:446
bool value_
Definition: MzTab.h:246
MzTabDoubleList retention_time_window
Definition: MzTab.h:625
MzTabString description
Definition: MzTab.h:517
Definition: MzTab.h:73
MzTabInteger reliability
Definition: MzTab.h:595
MzTabParameter id_format
Definition: MzTab.h:509
std::map< Size, MzTabParameter > peptide_search_engine_score
Definition: MzTab.h:534
std::map< Size, MzTabDouble > smallmolecule_abundance_std_error_study_variable
Definition: MzTab.h:689
MzTabString description
Definition: MzTab.h:587
Definition: MzTab.h:638
std::map< Size, MzTabDouble > smallmolecule_abundance_stdev_study_variable
Definition: MzTab.h:688
std::vector< MzTabDouble > entries_
Definition: MzTab.h:180
MzTabString pre
Definition: MzTab.h:656
std::map< Size, std::map< Size, MzTabDouble > > search_engine_score_ms_run
Definition: MzTab.h:594
MzTabInteger taxid
Definition: MzTab.h:675
MzTabString url
Definition: MzTab.h:487
MzTabParameter software
Definition: MzTab.h:463
MzTabDoubleList retention_time
Definition: MzTab.h:624
std::vector< MzTabParameter > parameters_
Definition: MzTab.h:334
Definition: MzTab.h:159
MzTabString species
Definition: MzTab.h:589
std::map< Size, MzTabSoftwareMetaData > software
Definition: MzTab.h:542
MzTabParameter format
Definition: MzTab.h:507
MzTabDouble protein_coverage
Definition: MzTab.h:603
MzTabModificationList modifications
Definition: MzTab.h:623
std::vector< int > ms_run_ref
Definition: MzTab.h:479
Interface for classes that can store arbitrary meta information (Type-Name-Value tuples).
Definition: MetaInfoInterface.h:55
MzTabStringList go_terms
Definition: MzTab.h:602
MzTabString mod_identifier_
Definition: MzTab.h:392
std::vector< MzTabPeptideSectionRow > MzTabPeptideSectionRows
Definition: MzTab.h:694
std::map< Size, MzTabDouble > protein_abundance_study_variable
Definition: MzTab.h:605
Definition: MzTab.h:451
std::map< Size, MzTabModificationMetaData > quantification_mod
Definition: MzTab.h:477
std::map< Size, MzTabParameterList > sample_processing
Definition: MzTab.h:538
MzTabDouble calc_mass_to_charge
Definition: MzTab.h:653
std::map< Size, std::map< Size, MzTabDouble > > search_engine_score_ms_run
Definition: MzTab.h:684
MzTabStringList ambiguity_members
Definition: MzTab.h:599
MzTabInteger charge
Definition: MzTab.h:651
MzTabString start
Definition: MzTab.h:658
std::map< Size, MzTabDouble > peptide_abundance_std_error_study_variable
Definition: MzTab.h:633
std::map< Size, MzTabDouble > smallmolecule_abundance_study_variable
Definition: MzTab.h:687
Definition: MzTab.h:513
MzTabParameter protein_quantification_unit
Definition: MzTab.h:558
Definition: MzTab.h:505
Definition: MzTab.h:461
Definition: MzTab.h:66
Definition: MzTab.h:137
MzTabParameter peptide_quantification_unit
Definition: MzTab.h:559
std::vector< String > colunit_peptide
Definition: MzTab.h:575
std::map< Size, MzTabMSRunMetaData > ms_run
Definition: MzTab.h:562
Definition: MzTab.h:96
std::map< Size, MzTabParameter > analyzer
Definition: MzTab.h:494
std::map< Size, MzTabDouble > best_search_engine_score
Definition: MzTab.h:593
MzTabParameter small_molecule_quantification_unit
Definition: MzTab.h:560
MzTabDouble exp_mass_to_charge
Definition: MzTab.h:671
std::vector< Size > empty_rows_
Definition: MzTab.h:792
MzTabParameterList search_engine
Definition: MzTab.h:682
Definition: MzTab.h:612
MzTabPSMSectionRows psm_data_
Definition: MzTab.h:790
MzTabString mz_tab_mode
Definition: MzTab.h:527
Definition: MzTab.h:68
std::map< Size, MzTabParameter > smallmolecule_search_engine_score
Definition: MzTab.h:536
size_t Size
Size type e.g. used as variable which can hold result of size()
Definition: Types.h:127
bool null_
Definition: MzTab.h:109
MzTabInteger PSM_ID
Definition: MzTab.h:641
String name_
Definition: MzTab.h:310
MzTabString email
Definition: MzTab.h:502
MzTabString database
Definition: MzTab.h:677
std::vector< std::pair< Size, MzTabParameter > > pos_param_pairs_
Definition: MzTab.h:391
MzTabString uri
Definition: MzTab.h:628
MzTabString description
Definition: MzTab.h:531
std::vector< MzTabString > entries_
Definition: MzTab.h:361
std::map< Size, MzTabDouble > search_engine_score
Definition: MzTab.h:647
MzTabInteger reliability
Definition: MzTab.h:679
Definition: MzTab.h:365
std::vector< MzTabPSMSectionRow > MzTabPSMSectionRows
Definition: MzTab.h:695
MzTabInteger charge
Definition: MzTab.h:626
MzTabInteger taxid
Definition: MzTab.h:588
MzTabString version
Definition: MzTab.h:486
MzTabSpectraRef spectra_ref
Definition: MzTab.h:655
MzTabString label
Definition: MzTab.h:484
std::map< Size, MzTabParameter > custom
Definition: MzTab.h:458
std::vector< MzTabOptionalColumnEntry > opt_
Definition: MzTab.h:608
MzTabBoolean unique
Definition: MzTab.h:643
MzTabParameter modification
Definition: MzTab.h:469
std::map< Size, MzTabInteger > num_psms_ms_run
Definition: MzTab.h:596
MzTabString database_version
Definition: MzTab.h:678
Definition: MzTab.h:205
std::map< Size, MzTabInteger > num_peptides_unique_ms_run
Definition: MzTab.h:598
MzTabString chemical_formula
Definition: MzTab.h:667
MzTabString database_version
Definition: MzTab.h:618
Definition: MzTab.h:395
MzTabString mz_tab_type
Definition: MzTab.h:528
MzTabParameter detector
Definition: MzTab.h:495
int Int
Signed integer type.
Definition: Types.h:102
std::vector< int > sample_refs
Definition: MzTab.h:516
MzTabDouble charge
Definition: MzTab.h:673
std::map< Size, MzTabInstrumentMetaData > instrument
Definition: MzTab.h:540
Definition: MzTab.h:183
String value_
Definition: MzTab.h:311
MzTabString database_version
Definition: MzTab.h:645
MzTabDouble exp_mass_to_charge
Definition: MzTab.h:652
std::map< Size, String > comment_rows_
Definition: MzTab.h:793
MzTabParameterList search_engine
Definition: MzTab.h:646
MzTabInteger reliability
Definition: MzTab.h:648
MzTabSmallMoleculeSectionRows small_molecule_data_
Definition: MzTab.h:791
std::map< Size, MzTabContactMetaData > contact
Definition: MzTab.h:548
MzTabString smiles
Definition: MzTab.h:668
std::pair< String, MzTabString > MzTabOptionalColumnEntry
Definition: MzTab.h:580
MzTabString location
Definition: MzTab.h:508
Definition: MzTab.h:65
Data model of MzTab files. Please see the official MzTab specification at https://code.google.com/p/mztab/.
Definition: MzTab.h:704
MzTabString site
Definition: MzTab.h:470