libpappsomspp
Library for mass spectrometry
|
#include <psmfeatures.h>
Public Member Functions | |
PsmFeatures (PrecisionPtr ms2precision, double minimumMz) | |
compute psm features | |
~PsmFeatures () | |
void | setPeptideSpectrumCharge (const pappso::PeptideSp peptideSp, const MassSpectrum *p_spectrum, unsigned int parent_charge, unsigned int max_isotope_number) |
double | getIntensityOfMatchedIon (Enums::PeptideIon ion_type) |
get the sum of intensity of a specific ion | |
double | getTotalIntensity () const |
sum of all peak intensities (matched or not) | |
double | getTotalIntensityOfMatchedIons () const |
sum of matched peak intensities | |
std::size_t | getNumberOfMatchedIons () const |
number of matched ions (peaks) | |
std::size_t | countMatchedIonComplementPairs () const |
count the number of matched ion complement | |
double | getTotalIntensityOfMatchedIonComplementPairs () const |
intensity of matched ion complement | |
const std::vector< std::pair< pappso::PeakIonIsotopeMatch, pappso::PeakIonIsotopeMatch > > & | getPeakIonPairs () const |
double | getMatchedMzDiffMean () const |
get mean deviation of matched peak mass delta | |
double | getMatchedMzDiffSd () const |
get standard deviation of matched peak mass delta | |
double | getMaxIntensityMatchedIonComplementPairPrecursorMassDelta () const |
get the precursor mass delta of the maximum intensity pair of complement ions | |
std::size_t | getMaxConsecutiveIon (Enums::PeptideIon ion_type) |
get the maximum consecutive fragments of one ion type | |
std::size_t | getAaSequenceCoverage (Enums::PeptideIon ion_type) |
number of amino acid covered by matched ions | |
std::size_t | getComplementPairsAaSequenceCoverage () |
number of amino acid covered by matched complement pairs of ions | |
double | getMaxIntensityPeakIonMatch (Enums::PeptideIon ion_type) const |
double | getIonPairPrecursorMassDelta (const std::pair< pappso::PeakIonIsotopeMatch, pappso::PeakIonIsotopeMatch > &ion_pair) const |
LinearRegression | getIonIsotopeLinearRegression () const |
Private Member Functions | |
void | findComplementIonPairs (const pappso::PeptideSp &peptideSp) |
Private Attributes | |
std::shared_ptr< FilterResampleKeepGreater > | msp_filterKeepGreater |
std::shared_ptr< PeptideIsotopeSpectrumMatch > | msp_peptideSpectrumMatch |
pappso::PeptideSp | msp_peptide |
PrecisionPtr | m_ms2precision |
std::list< Enums::PeptideIon > | m_ionList |
double | m_spectrumSumIntensity |
double | m_precursorTheoreticalMz |
double | m_precursorTheoreticalMass |
unsigned int | m_parentCharge = 1 |
std::vector< std::pair< pappso::PeakIonIsotopeMatch, pappso::PeakIonIsotopeMatch > > | m_peakIonPairs |
double | m_matchedMzDiffMean = 0 |
double | m_matchedMzDiffMedian = 0 |
double | m_matchedMzDiffSd = 0 |
Definition at line 45 of file psmfeatures.h.
PsmFeatures::PsmFeatures | ( | PrecisionPtr | ms2precision, |
double | minimumMz ) |
compute psm features
ms2precision | precision of mass measurements for MS2 fragments |
minimumMz | ignore mz values under this threshold |
Definition at line 35 of file psmfeatures.cpp.
References pappso::Enums::b, m_ionList, m_ms2precision, msp_filterKeepGreater, and pappso::Enums::y.
PsmFeatures::~PsmFeatures | ( | ) |
std::size_t pappso::PsmFeatures::countMatchedIonComplementPairs | ( | ) | const |
count the number of matched ion complement
matched ion complement are ions with a sum compatible to the precursor mass
Definition at line 158 of file psmfeatures.cpp.
References m_peakIonPairs.
|
private |
Definition at line 343 of file psmfeatures.cpp.
References pappso::findComplementIonType(), m_peakIonPairs, msp_peptideSpectrumMatch, pappso::peptideIonIsNter(), and pappso::Peptide::size().
Referenced by setPeptideSpectrumCharge().
std::size_t pappso::PsmFeatures::getAaSequenceCoverage | ( | Enums::PeptideIon | ion_type | ) |
number of amino acid covered by matched ions
Definition at line 254 of file psmfeatures.cpp.
References msp_peptide, and msp_peptideSpectrumMatch.
std::size_t pappso::PsmFeatures::getComplementPairsAaSequenceCoverage | ( | ) |
number of amino acid covered by matched complement pairs of ions
Definition at line 273 of file psmfeatures.cpp.
References m_peakIonPairs, and msp_peptide.
double PsmFeatures::getIntensityOfMatchedIon | ( | Enums::PeptideIon | ion_type | ) |
get the sum of intensity of a specific ion
ion_type | ion species (y, b, ...) |
Definition at line 128 of file psmfeatures.cpp.
References msp_peptideSpectrumMatch.
LinearRegression pappso::PsmFeatures::getIonIsotopeLinearRegression | ( | ) | const |
experimental use with caution
Definition at line 365 of file psmfeatures.cpp.
References pappso::PeptideNaturalIsotopeAverage::getIntensityRatio(), pappso::PeptideNaturalIsotopeAverage::getIsotopeNumber(), m_ionList, msp_peptide, msp_peptideSpectrumMatch, and pappso::Trace::sortX().
double pappso::PsmFeatures::getIonPairPrecursorMassDelta | ( | const std::pair< pappso::PeakIonIsotopeMatch, pappso::PeakIonIsotopeMatch > & | ion_pair | ) | const |
Definition at line 327 of file psmfeatures.cpp.
References m_parentCharge, m_precursorTheoreticalMass, m_precursorTheoreticalMz, and pappso::MHPLUS().
Referenced by getMaxIntensityMatchedIonComplementPairPrecursorMassDelta().
double pappso::PsmFeatures::getMatchedMzDiffMean | ( | ) | const |
get mean deviation of matched peak mass delta
Definition at line 189 of file psmfeatures.cpp.
References m_matchedMzDiffMean.
double pappso::PsmFeatures::getMatchedMzDiffSd | ( | ) | const |
get standard deviation of matched peak mass delta
Definition at line 183 of file psmfeatures.cpp.
References m_matchedMzDiffSd.
std::size_t pappso::PsmFeatures::getMaxConsecutiveIon | ( | Enums::PeptideIon | ion_type | ) |
get the maximum consecutive fragments of one ion type
ion_type | ion species (y, b, ...) |
Definition at line 202 of file psmfeatures.cpp.
References pappso::a, pappso::b, and msp_peptideSpectrumMatch.
double pappso::PsmFeatures::getMaxIntensityMatchedIonComplementPairPrecursorMassDelta | ( | ) | const |
get the precursor mass delta of the maximum intensity pair of complement ions
Definition at line 309 of file psmfeatures.cpp.
References pappso::a, pappso::b, getIonPairPrecursorMassDelta(), and m_peakIonPairs.
double pappso::PsmFeatures::getMaxIntensityPeakIonMatch | ( | Enums::PeptideIon | ion_type | ) | const |
Definition at line 290 of file psmfeatures.cpp.
References pappso::a, pappso::b, and msp_peptideSpectrumMatch.
std::size_t pappso::PsmFeatures::getNumberOfMatchedIons | ( | ) | const |
number of matched ions (peaks)
Definition at line 196 of file psmfeatures.cpp.
References msp_peptideSpectrumMatch.
const std::vector< std::pair< pappso::PeakIonIsotopeMatch, pappso::PeakIonIsotopeMatch > > & pappso::PsmFeatures::getPeakIonPairs | ( | ) | const |
Definition at line 164 of file psmfeatures.cpp.
References m_peakIonPairs.
double PsmFeatures::getTotalIntensity | ( | ) | const |
sum of all peak intensities (matched or not)
Definition at line 152 of file psmfeatures.cpp.
References m_spectrumSumIntensity.
double pappso::PsmFeatures::getTotalIntensityOfMatchedIonComplementPairs | ( | ) | const |
intensity of matched ion complement
Definition at line 170 of file psmfeatures.cpp.
References m_peakIonPairs.
double PsmFeatures::getTotalIntensityOfMatchedIons | ( | ) | const |
sum of matched peak intensities
Definition at line 141 of file psmfeatures.cpp.
References msp_peptideSpectrumMatch.
void PsmFeatures::setPeptideSpectrumCharge | ( | const pappso::PeptideSp | peptideSp, |
const MassSpectrum * | p_spectrum, | ||
unsigned int | parent_charge, | ||
unsigned int | max_isotope_number ) |
Definition at line 57 of file psmfeatures.cpp.
References findComplementIonPairs(), pappso::Peptide::getMass(), pappso::Ion::getMz(), m_ionList, m_matchedMzDiffMean, m_matchedMzDiffMedian, m_matchedMzDiffSd, m_ms2precision, m_parentCharge, m_peakIonPairs, m_precursorTheoreticalMass, m_precursorTheoreticalMz, m_spectrumSumIntensity, msp_filterKeepGreater, msp_peptide, msp_peptideSpectrumMatch, and pappso::Trace::sumY().
|
private |
Definition at line 149 of file psmfeatures.h.
Referenced by PsmFeatures(), getIonIsotopeLinearRegression(), and setPeptideSpectrumCharge().
|
private |
Definition at line 159 of file psmfeatures.h.
Referenced by getMatchedMzDiffMean(), and setPeptideSpectrumCharge().
|
private |
Definition at line 160 of file psmfeatures.h.
Referenced by setPeptideSpectrumCharge().
|
private |
Definition at line 161 of file psmfeatures.h.
Referenced by getMatchedMzDiffSd(), and setPeptideSpectrumCharge().
|
private |
Definition at line 148 of file psmfeatures.h.
Referenced by PsmFeatures(), and setPeptideSpectrumCharge().
|
private |
Definition at line 155 of file psmfeatures.h.
Referenced by getIonPairPrecursorMassDelta(), and setPeptideSpectrumCharge().
|
private |
Definition at line 157 of file psmfeatures.h.
Referenced by countMatchedIonComplementPairs(), findComplementIonPairs(), getComplementPairsAaSequenceCoverage(), getMaxIntensityMatchedIonComplementPairPrecursorMassDelta(), getPeakIonPairs(), getTotalIntensityOfMatchedIonComplementPairs(), and setPeptideSpectrumCharge().
|
private |
Definition at line 154 of file psmfeatures.h.
Referenced by getIonPairPrecursorMassDelta(), and setPeptideSpectrumCharge().
|
private |
Definition at line 153 of file psmfeatures.h.
Referenced by getIonPairPrecursorMassDelta(), and setPeptideSpectrumCharge().
|
private |
Definition at line 151 of file psmfeatures.h.
Referenced by getTotalIntensity(), and setPeptideSpectrumCharge().
|
private |
Definition at line 143 of file psmfeatures.h.
Referenced by PsmFeatures(), and setPeptideSpectrumCharge().
|
private |
Definition at line 146 of file psmfeatures.h.
Referenced by getAaSequenceCoverage(), getComplementPairsAaSequenceCoverage(), getIonIsotopeLinearRegression(), and setPeptideSpectrumCharge().
|
private |
Definition at line 145 of file psmfeatures.h.
Referenced by findComplementIonPairs(), getAaSequenceCoverage(), getIntensityOfMatchedIon(), getIonIsotopeLinearRegression(), getMaxConsecutiveIon(), getMaxIntensityPeakIonMatch(), getNumberOfMatchedIons(), getTotalIntensityOfMatchedIons(), and setPeptideSpectrumCharge().