| 
    libpappsomspp
    
   Library for mass spectrometry 
   | 
 
#include <peptidemodel.h>
 Public Member Functions | |
| PeptideModel (const pappso::QualifiedMassSpectrum &qmass_spectrum, const pappso::Peptide &peptide) | |
| PeptideModel () | |
| PeptideModel (const PeptideModel &other) | |
| virtual | ~PeptideModel () | 
| QString | toString () const | 
| double | getMass () const | 
| pappso_double | getMz (unsigned int charge) const | 
| get the m/z peptide model mass   | |
| double | getMassDelta () const | 
| mass delta between experimental and theoretical mass   | |
| std::size_t | modifCount () const | 
| void | setBeginMassDelta (double) | 
| void | matchExperimentalPeaks (pappso::PrecisionPtr precision) | 
| std::vector< double > | getTheoreticalIonMassList () const | 
| std::size_t | getCountSharedPeaks () const | 
| double | getIntensitySharedPeaks () const | 
| double | getIntensityExperimentalPeaks () const | 
| void | assignResidualMass2Cter () | 
| bool | eliminateComplementaryDelta (pappso::PrecisionPtr precision) | 
| bool | checkForMutations (const std::vector< Enums::AminoAcidChar > &aa_list, pappso::PrecisionPtr precision) | 
| try to replace mass differences with corresponding mutations mass delta   | |
| bool | checkForMutation (const pappso::Aa &amino_acid_candidate, pappso::PrecisionPtr precision) | 
| try to replace mass differences with corresponding mutation mass delta   | |
| bool | checkForAaModification (const pappso::Aa &aa_modified, pappso::PrecisionPtr precision) | 
| try to replace mass differences with the given modifications on a specific amino acid   | |
| bool | checkForAaModificationP (pappso::AaModificationP modification, pappso::PrecisionPtr precision) | 
| try to replace mass differences with the given modification   | |
| PeptideModel & | operator= (const PeptideModel &other) | 
| PeptideModel & | copyDeep (const PeptideModel &other) | 
| bool | eliminateNegativeOffset (pappso::PrecisionPtr precision) | 
| bool | removeBracketsForAlignedAA () | 
| const std::vector< TheoreticalPeakDataPoint > & | getTheoreticalPeakDataPointList () const | 
| QString | getTheoreticalPeakDataPointListToString () const | 
| QString | toProForma () const | 
| get the peptide model in ProForma notation https://github.com/HUPO-PSI/ProForma/blob/master/README.md   | |
| bool | hasRemoval () const | 
| bool | ltrimOnRemoval () | 
| try to remove left amino acid if there is a removal   | |
Private Member Functions | |
| void | generateTheoreticalPeaks (pappso::PrecisionPtr precision) | 
Private Attributes | |
| std::vector< TheoreticalPeakDataPoint > | m_theoreticalPeakList | 
| double | m_experimentalPrecursorMass | 
| double | m_beginMassDelta = 0 | 
| pappso::MassSpectrumCstSPtr | mcsp_peakList = nullptr | 
| pappso::AaModificationP | m_nterModification | 
| pappso::AaModificationP | m_cterModification | 
| std::size_t | m_countSharedPeaks = 0 | 
| double | m_intensitySharedPeaks = 0 | 
| double | m_intensityExperimentalPeaks = 0 | 
Definition at line 72 of file peptidemodel.h.
| pappso::specglob::PeptideModel::PeptideModel | ( | const pappso::QualifiedMassSpectrum & | qmass_spectrum, | 
| const pappso::Peptide & | peptide ) | 
Default constructor
Definition at line 53 of file peptidemodel.cpp.
References pappso::Peptide::getCleavageCterModification(), pappso::Peptide::getCleavageNterModification(), pappso::QualifiedMassSpectrum::getMassSpectrumCstSPtr(), pappso::QualifiedMassSpectrum::getPrecursorMass(), m_cterModification, m_experimentalPrecursorMass, m_nterModification, mcsp_peakList, and pappso::specglob::nonAlign.
Referenced by PeptideModel(), copyDeep(), and operator=().
| pappso::specglob::PeptideModel::PeptideModel | ( | ) | 
Definition at line 48 of file peptidemodel.cpp.
| pappso::specglob::PeptideModel::PeptideModel | ( | const PeptideModel & | other | ) | 
Copy constructor
| other | TODO | 
Definition at line 73 of file peptidemodel.cpp.
References PeptideModel(), m_beginMassDelta, m_countSharedPeaks, m_cterModification, m_experimentalPrecursorMass, m_intensityExperimentalPeaks, m_intensitySharedPeaks, m_nterModification, and mcsp_peakList.
      
  | 
  virtual | 
| void pappso::specglob::PeptideModel::assignResidualMass2Cter | ( | ) | 
Definition at line 458 of file peptidemodel.cpp.
References getMassDelta().
| bool pappso::specglob::PeptideModel::checkForAaModification | ( | const pappso::Aa & | aa_modified, | 
| pappso::PrecisionPtr | precision ) | 
try to replace mass differences with the given modifications on a specific amino acid
| aa_modified | the modified amino acid | 
| precision | The mass spectrometer precision | 
Definition at line 769 of file peptidemodel.cpp.
References pappso::AaBase::getLetter(), pappso::Aa::getModificationList(), pappso::PrecisionBase::getNominal(), pappso::Aa::getTotalModificationMass(), and m_beginMassDelta.
| bool pappso::specglob::PeptideModel::checkForAaModificationP | ( | pappso::AaModificationP | modification, | 
| pappso::PrecisionPtr | precision ) | 
try to replace mass differences with the given modification
| modification | : The proposed modification pointer | 
| precision | : The mass spectrometer precision | 
Definition at line 742 of file peptidemodel.cpp.
References pappso::AaModification::getMass(), pappso::PrecisionBase::getNominal(), and m_beginMassDelta.
| bool pappso::specglob::PeptideModel::checkForMutation | ( | const pappso::Aa & | amino_acid_candidate, | 
| pappso::PrecisionPtr | precision ) | 
try to replace mass differences with corresponding mutation mass delta
amino acid candidate tested could bear some modifications
| amino_acid_candidate | : The amino acid candidate to check | 
| precision | : The mass spectrometer precision | 
Definition at line 643 of file peptidemodel.cpp.
References pappso::AaModification::getInstanceInsertionAccessionByAaLetter(), pappso::AaModification::getInstanceRemovalAccessionByAaLetter(), pappso::AaBase::getLetter(), pappso::Aa::getMass(), pappso::AaModification::getMass(), pappso::Aa::getModificationList(), pappso::PrecisionBase::getNominal(), and m_beginMassDelta.
| bool pappso::specglob::PeptideModel::checkForMutations | ( | const std::vector< Enums::AminoAcidChar > & | aa_list, | 
| pappso::PrecisionPtr | precision ) | 
try to replace mass differences with corresponding mutations mass delta
amino acid list is tested as raw (no modification)
| aa_list | amno acid list to test (beware of cysteine + carbamidomethyl) | 
| precision | : The mass spectrometer precision | 
Definition at line 686 of file peptidemodel.cpp.
References pappso::AaModification::getInstanceInsertionAccessionByAaLetter(), pappso::AaModification::getInstanceRemovalAccessionByAaLetter(), pappso::AaModification::getMass(), pappso::PrecisionBase::getNominal(), and m_beginMassDelta.
| PeptideModel & pappso::specglob::PeptideModel::copyDeep | ( | const PeptideModel & | other | ) | 
Definition at line 109 of file peptidemodel.cpp.
References PeptideModel(), m_theoreticalPeakList, and operator=().
Referenced by pappso::specglob::PostTreatment::tryBetterPositionOffsets(), pappso::specglob::PostTreatment::tryToCumulateOffSets(), and pappso::specglob::PostTreatment::tryToRemoveOffsets().
| bool pappso::specglob::PeptideModel::eliminateComplementaryDelta | ( | pappso::PrecisionPtr | precision | ) | 
Use to delete offset when there is two opposite mass in the hit modified example : [150.2]SDS[-150.2]KR --> SDSKR
| precision | : The mass spectrometer precision | 
Definition at line 464 of file peptidemodel.cpp.
References pappso::PrecisionBase::getNominal(), m_beginMassDelta, pappso::specglob::AminoAcidModel::mass_difference, and toString().
Referenced by pappso::specglob::PostTreatment::findBetterPeptideModel(), and pappso::specglob::SpectralAlignment::rtrim().
| bool pappso::specglob::PeptideModel::eliminateNegativeOffset | ( | pappso::PrecisionPtr | precision | ) | 
Use to try to explain negative offset with deletion of amino acids
| precision | : The mass spectrometer precision | 
Definition at line 541 of file peptidemodel.cpp.
References pappso::PrecisionBase::getNominal().
Referenced by pappso::specglob::PostTreatment::findBetterPeptideModel().
      
  | 
  private | 
Definition at line 387 of file peptidemodel.cpp.
References pappso::a, pappso::b, pappso::PeptideRawFragmentMasses::getDeltaMass(), m_beginMassDelta, m_nterModification, m_theoreticalPeakList, mcsp_peakList, pappso::MHPLUS(), pappso::MPROTIUM(), and pappso::Enums::y.
Referenced by matchExperimentalPeaks().
| std::size_t pappso::specglob::PeptideModel::getCountSharedPeaks | ( | ) | const | 
Definition at line 440 of file peptidemodel.cpp.
References m_countSharedPeaks.
Referenced by pappso::specglob::PostTreatment::findBetterPeptideModel(), pappso::cbor::psm::PsmSpecGlobScan::process(), pappso::specglob::PostTreatment::tryBetterPositionOffsets(), pappso::specglob::PostTreatment::tryToCumulateOffSets(), and pappso::specglob::PostTreatment::tryToRemoveOffsets().
| double pappso::specglob::PeptideModel::getIntensityExperimentalPeaks | ( | ) | const | 
Definition at line 452 of file peptidemodel.cpp.
References m_intensityExperimentalPeaks.
| double pappso::specglob::PeptideModel::getIntensitySharedPeaks | ( | ) | const | 
Definition at line 446 of file peptidemodel.cpp.
References m_intensitySharedPeaks.
| double pappso::specglob::PeptideModel::getMass | ( | ) | const | 
Definition at line 277 of file peptidemodel.cpp.
References m_beginMassDelta, m_cterModification, and m_nterModification.
Referenced by getMassDelta(), and getMz().
| double pappso::specglob::PeptideModel::getMassDelta | ( | ) | const | 
mass delta between experimental and theoretical mass
Definition at line 293 of file peptidemodel.cpp.
References getMass(), and m_experimentalPrecursorMass.
Referenced by assignResidualMass2Cter(), toProForma(), and toString().
| double pappso::specglob::PeptideModel::getMz | ( | unsigned int | charge | ) | const | 
get the m/z peptide model mass
Definition at line 122 of file peptidemodel.cpp.
References getMass(), and pappso::MHPLUS().
| std::vector< double > pappso::specglob::PeptideModel::getTheoreticalIonMassList | ( | ) | const | 
Definition at line 429 of file peptidemodel.cpp.
References m_theoreticalPeakList.
| const std::vector< TheoreticalPeakDataPoint > & pappso::specglob::PeptideModel::getTheoreticalPeakDataPointList | ( | ) | const | 
Definition at line 615 of file peptidemodel.cpp.
References m_theoreticalPeakList.
| QString pappso::specglob::PeptideModel::getTheoreticalPeakDataPointListToString | ( | ) | const | 
Definition at line 621 of file peptidemodel.cpp.
References m_theoreticalPeakList, and mcsp_peakList.
| bool pappso::specglob::PeptideModel::hasRemoval | ( | ) | const | 
Definition at line 173 of file peptidemodel.cpp.
| bool pappso::specglob::PeptideModel::ltrimOnRemoval | ( | ) | 
try to remove left amino acid if there is a removal
Definition at line 184 of file peptidemodel.cpp.
References pappso::specglob::AminoAcidModel::amino_acid, and pappso::Aa::getMass().
Referenced by pappso::specglob::SpectralAlignment::rtrim().
| void pappso::specglob::PeptideModel::matchExperimentalPeaks | ( | pappso::PrecisionPtr | precision | ) | 
Definition at line 319 of file peptidemodel.cpp.
References generateTheoreticalPeaks(), m_countSharedPeaks, m_intensityExperimentalPeaks, m_intensitySharedPeaks, m_theoreticalPeakList, and mcsp_peakList.
Referenced by pappso::specglob::PostTreatment::findBetterPeptideModel(), pappso::specglob::PostTreatment::tryBetterPositionOffsets(), pappso::specglob::PostTreatment::tryToCumulateOffSets(), and pappso::specglob::PostTreatment::tryToRemoveOffsets().
| std::size_t pappso::specglob::PeptideModel::modifCount | ( | ) | const | 
Definition at line 299 of file peptidemodel.cpp.
References m_beginMassDelta.
| PeptideModel & pappso::specglob::PeptideModel::operator= | ( | const PeptideModel & | other | ) | 
Definition at line 89 of file peptidemodel.cpp.
References PeptideModel(), m_beginMassDelta, m_countSharedPeaks, m_cterModification, m_experimentalPrecursorMass, m_intensityExperimentalPeaks, m_intensitySharedPeaks, m_nterModification, m_theoreticalPeakList, and mcsp_peakList.
Referenced by copyDeep().
| bool pappso::specglob::PeptideModel::removeBracketsForAlignedAA | ( | ) | 
Use to remove brackets around not found Amino acids when the B or Y peak corresponding to the amino acid in the sequence is in the experimental peak list
| betterModified | : The better sequence of hit Modified | 
| experimentalMassList | : The list of mass that are in the experimental spectrum | 
| precision | : The precision of the mass spectrometer | 
Definition at line 592 of file peptidemodel.cpp.
References m_theoreticalPeakList, and mcsp_peakList.
| void pappso::specglob::PeptideModel::setBeginMassDelta | ( | double | delta | ) | 
Definition at line 313 of file peptidemodel.cpp.
References m_beginMassDelta.
Referenced by pappso::specglob::SpectralAlignment::buildPeptideModel().
| QString pappso::specglob::PeptideModel::toProForma | ( | ) | const | 
get the peptide model in ProForma notation https://github.com/HUPO-PSI/ProForma/blob/master/README.md
Definition at line 213 of file peptidemodel.cpp.
References pappso::AaModification::getInstanceRemovalAccessionByAaLetter(), getMassDelta(), m_beginMassDelta, and pappso::Utils::toString().
Referenced by pappso::cbor::psm::PsmSpecGlobScan::process().
| QString pappso::specglob::PeptideModel::toString | ( | ) | const | 
Definition at line 128 of file peptidemodel.cpp.
References getMassDelta(), m_beginMassDelta, and pappso::Utils::toString().
Referenced by eliminateComplementaryDelta(), pappso::specglob::PostTreatment::findBetterPeptideModel(), pappso::cbor::psm::PsmSpecGlobScan::process(), pappso::specglob::PostTreatment::tryBetterPositionOffsets(), and pappso::specglob::PostTreatment::tryToRemoveOffsets().
      
  | 
  private | 
Definition at line 224 of file peptidemodel.h.
Referenced by PeptideModel(), checkForAaModification(), checkForAaModificationP(), checkForMutation(), checkForMutations(), eliminateComplementaryDelta(), generateTheoreticalPeaks(), getMass(), modifCount(), operator=(), setBeginMassDelta(), toProForma(), and toString().
      
  | 
  private | 
Definition at line 230 of file peptidemodel.h.
Referenced by PeptideModel(), getCountSharedPeaks(), matchExperimentalPeaks(), and operator=().
      
  | 
  private | 
Definition at line 228 of file peptidemodel.h.
Referenced by PeptideModel(), PeptideModel(), getMass(), and operator=().
      
  | 
  private | 
Definition at line 223 of file peptidemodel.h.
Referenced by PeptideModel(), PeptideModel(), getMassDelta(), and operator=().
      
  | 
  private | 
Definition at line 232 of file peptidemodel.h.
Referenced by PeptideModel(), getIntensityExperimentalPeaks(), matchExperimentalPeaks(), and operator=().
      
  | 
  private | 
Definition at line 231 of file peptidemodel.h.
Referenced by PeptideModel(), getIntensitySharedPeaks(), matchExperimentalPeaks(), and operator=().
      
  | 
  private | 
Definition at line 227 of file peptidemodel.h.
Referenced by PeptideModel(), PeptideModel(), generateTheoreticalPeaks(), getMass(), and operator=().
      
  | 
  private | 
Definition at line 221 of file peptidemodel.h.
Referenced by copyDeep(), generateTheoreticalPeaks(), getTheoreticalIonMassList(), getTheoreticalPeakDataPointList(), getTheoreticalPeakDataPointListToString(), matchExperimentalPeaks(), operator=(), and removeBracketsForAlignedAA().
      
  | 
  private | 
Definition at line 225 of file peptidemodel.h.
Referenced by PeptideModel(), PeptideModel(), generateTheoreticalPeaks(), getTheoreticalPeakDataPointListToString(), matchExperimentalPeaks(), operator=(), and removeBracketsForAlignedAA().