OpenMS
Loading...
Searching...
No Matches
NuXLReport.h
Go to the documentation of this file.
1// Copyright (c) 2002-present, The OpenMS Team -- EKU Tuebingen, ETH Zurich, and FU Berlin
2// SPDX-License-Identifier: BSD-3-Clause
3//
4// --------------------------------------------------------------------------
5// $Maintainer: Timo Sachsenberg $
6// $Authors: Timo Sachsenberg $
7// --------------------------------------------------------------------------
8
9#pragma once
10
14
21
22#include <vector>
23
24namespace OpenMS
25{
26
28struct OPENMS_DLLAPI NuXLReportRow
29{
30 bool no_id;
31
32 // columns
33 double rt;
35 std::string accessions;
36 std::string peptide;
37 std::string NA;
39 double score;
40 int rank;
43 std::string best_localization;
45 double NA_weight;
46 double xl_weight;
47 StringList meta_values; // the actual values of exported metadata
51 double m_H;
52 double m_2H;
53 double m_3H;
54 double m_4H;
56 std::string getString(const std::string& separator) const;
57};
58
60struct OPENMS_DLLAPI NuXLReportRowHeader
61{
62 static std::string getString(const std::string& separator, const StringList& meta_values_to_export);
63};
64
66struct OPENMS_DLLAPI NuXLReport
67{
68 static std::vector<NuXLReportRow> annotate(
69 const PeakMap& spectra,
70 PeptideIdentificationList& peptide_ids,
71 const StringList& meta_values_to_export,
72 double marker_ions_tolerance);
73};
74
75
77struct OPENMS_DLLAPI NuXLProteinReport
78{
79 static void annotateProteinModificationForTopHits(std::vector<ProteinIdentification>& prot_ids,
80 const PeptideIdentificationList& peps,
81 TextFile& tsv_file);
82
83 // crosslink efficiency = frequency of the crosslinked amino acid / frequency of the amino acid in all crosslink spectrum matches
84 static std::map<char, double> getCrossLinkEfficiency(const PeptideIdentificationList& peps);
85
86 // returns map of adduct to counts
87 static std::map<std::string, size_t> countAdducts(const PeptideIdentificationList& peps);
88
89 static void mapAccessionToTDProteins(ProteinIdentification& prot_id, std::map<std::string, ProteinHit*>& acc2protein_targets, std::map<std::string, ProteinHit*>& acc2protein_decoys);
90};
91
92}
In-Memory representation of a mass spectrometry run.
Definition MSExperiment.h:49
Container for peptide identifications from multiple spectra.
Definition PeptideIdentificationList.h:66
Representation of a protein identification run.
Definition ProteinIdentification.h:55
Definition TextFile.h:21
int Int
Signed integer type.
Definition Types.h:72
std::vector< std::string > StringList
Vector of String.
Definition ListUtils.h:44
Main OpenMS namespace.
Definition openswathalgo/include/OpenMS/OPENSWATHALGO/DATAACCESS/ISpectrumAccess.h:19
std::map< std::string, std::vector< std::pair< double, double > > > MarkerIonsType
name to mass-intensity pair
Definition NuXLMarkerIonExtractor.h:23
protein report
Definition NuXLReport.h:78
static void annotateProteinModificationForTopHits(std::vector< ProteinIdentification > &prot_ids, const PeptideIdentificationList &peps, TextFile &tsv_file)
static std::map< std::string, size_t > countAdducts(const PeptideIdentificationList &peps)
static std::map< char, double > getCrossLinkEfficiency(const PeptideIdentificationList &peps)
static void mapAccessionToTDProteins(ProteinIdentification &prot_id, std::map< std::string, ProteinHit * > &acc2protein_targets, std::map< std::string, ProteinHit * > &acc2protein_decoys)
create header line
Definition NuXLReport.h:61
static std::string getString(const std::string &separator, const StringList &meta_values_to_export)
struct to hold a single report line
Definition NuXLReport.h:29
std::string peptide
Definition NuXLReport.h:36
bool no_id
Definition NuXLReport.h:30
double m_H
Definition NuXLReport.h:51
double m_3H
Definition NuXLReport.h:53
std::string fragment_annotation
Definition NuXLReport.h:55
std::string localization_scores
Definition NuXLReport.h:42
std::string getString(const std::string &separator) const
double best_localization_score
Definition NuXLReport.h:41
double score
Definition NuXLReport.h:39
NuXLMarkerIonExtractor::MarkerIonsType marker_ions
Definition NuXLReport.h:48
StringList meta_values
Definition NuXLReport.h:47
double peptide_weight
Definition NuXLReport.h:44
double m_4H
Definition NuXLReport.h:54
double NA_weight
Definition NuXLReport.h:45
int rank
Definition NuXLReport.h:40
double rel_prec_error
Definition NuXLReport.h:50
Int charge
Definition NuXLReport.h:38
std::string NA
Definition NuXLReport.h:37
double xl_weight
Definition NuXLReport.h:46
double m_2H
Definition NuXLReport.h:52
std::string best_localization
Definition NuXLReport.h:43
double original_mz
Definition NuXLReport.h:34
double abs_prec_error
Definition NuXLReport.h:49
std::string accessions
Definition NuXLReport.h:35
double rt
Definition NuXLReport.h:33
create PSM report
Definition NuXLReport.h:67
static std::vector< NuXLReportRow > annotate(const PeakMap &spectra, PeptideIdentificationList &peptide_ids, const StringList &meta_values_to_export, double marker_ions_tolerance)