OpenMS
Loading...
Searching...
No Matches
XQuestScores Class Reference

An implementation of the scores for cross-link identification from the xQuest algorithm (O. Rinner et al., 2008, "Identification of cross-linked peptides from large sequence databases") More...

#include <OpenMS/ANALYSIS/XLMS/XQuestScores.h>

Static Public Member Functions

static float preScore (Size matched_alpha, Size ions_alpha, Size matched_beta, Size ions_beta)
 compute a simple and fast to compute pre-score for a cross-link spectrum match
 
static float preScore (Size matched_alpha, Size ions_alpha)
 compute a simple and fast to compute pre-score for a mono-link spectrum match
 
static double matchOddsScore (const PeakSpectrum &theoretical_spec, const Size matched_size, double fragment_mass_tolerance, bool fragment_mass_tolerance_unit_ppm, bool is_xlink_spectrum=false, Size n_charges=1)
 compute the match-odds score, a score based on the probability of getting the given number of matched peaks by chance
 
static double matchOddsScoreSimpleSpec (const std::vector< SimpleTSGXLMS::SimplePeak > &theoretical_spec, const Size matched_size, double fragment_mass_tolerance, bool fragment_mass_tolerance_unit_ppm, bool is_xlink_spectrum=false, Size n_charges=1)
 
static double logOccupancyProb (const PeakSpectrum &theoretical_spec, const Size matched_size, double fragment_mass_tolerance, bool fragment_mass_tolerance_unit_ppm)
 compute the logOccupancyProb score, similar to the match_odds, a score based on the probability of getting the given number of matched peaks by chance
 
static double weightedTICScoreXQuest (Size alpha_size, Size beta_size, double intsum_alpha, double intsum_beta, double total_current, bool type_is_cross_link)
 compute the weighted total ion current score for a cross-link. Reimplementation from xQuest.
 
static double weightedTICScore (Size alpha_size, Size beta_size, double intsum_alpha, double intsum_beta, double total_current, bool type_is_cross_link)
 compute the weighted total ion current score for a cross-link. Scaling changed from original xQuest.
 
static double matchedCurrentChain (const std::vector< std::pair< Size, Size > > &matched_spec_linear, const std::vector< std::pair< Size, Size > > &matched_spec_xlinks, const PeakSpectrum &spectrum_linear_peaks, const PeakSpectrum &spectrum_xlink_peaks)
 computes sum of peak intensities of matched peaks for either the alpha or the beta peptide
 
static double totalMatchedCurrent (const std::vector< std::pair< Size, Size > > &matched_spec_linear_alpha, const std::vector< std::pair< Size, Size > > &matched_spec_linear_beta, const std::vector< std::pair< Size, Size > > &matched_spec_xlinks_alpha, const std::vector< std::pair< Size, Size > > &matched_spec_xlinks_beta, const PeakSpectrum &spectrum_linear_peaks, const PeakSpectrum &spectrum_xlink_peaks)
 computes sum of peak intensities of all matched peaks
 
static std::vector< double > xCorrelation (const PeakSpectrum &spec1, const PeakSpectrum &spec2, Int maxshift, double tolerance)
 computes a crude cross-correlation between two spectra. Crude, because it uses a static binsize based on a tolerance in Da and it uses equal intensities for all peaks
 
static double xCorrelationPrescore (const PeakSpectrum &spec1, const PeakSpectrum &spec2, double tolerance)
 computes a crude dot product between two spectra. Crude, because it uses a static binsize based on a tolerance in Da and it uses equal intensities for all peaks
 

Detailed Description

An implementation of the scores for cross-link identification from the xQuest algorithm (O. Rinner et al., 2008, "Identification of cross-linked peptides from large sequence databases")

Member Function Documentation

◆ logOccupancyProb()

static double logOccupancyProb ( const PeakSpectrum theoretical_spec,
const Size  matched_size,
double  fragment_mass_tolerance,
bool  fragment_mass_tolerance_unit_ppm 
)
static

compute the logOccupancyProb score, similar to the match_odds, a score based on the probability of getting the given number of matched peaks by chance

Parameters
[in]theoretical_spectheoretical spectrum, sorted by position
[in]matched_sizenumber of matched peaks between experimental and theoretical spectra
[in]fragment_mass_tolerancethe tolerance of the alignment
[in]fragment_mass_tolerance_unit_ppmthe tolerance unit of the alignment, true = ppm, false = Da

◆ matchedCurrentChain()

static double matchedCurrentChain ( const std::vector< std::pair< Size, Size > > &  matched_spec_linear,
const std::vector< std::pair< Size, Size > > &  matched_spec_xlinks,
const PeakSpectrum spectrum_linear_peaks,
const PeakSpectrum spectrum_xlink_peaks 
)
static

computes sum of peak intensities of matched peaks for either the alpha or the beta peptide

Parameters
[in]matched_spec_linearalignment between linear alpha or beta ions and linear experimental peaks
[in]matched_spec_xlinksalignment between xlink alpha or beta ions and xlink experimental peaks
[in]spectrum_linear_peaksexperimental linear ion spectrum
[in]spectrum_xlink_peaksexperimental xlink spectrum

◆ matchOddsScore()

static double matchOddsScore ( const PeakSpectrum theoretical_spec,
const Size  matched_size,
double  fragment_mass_tolerance,
bool  fragment_mass_tolerance_unit_ppm,
bool  is_xlink_spectrum = false,
Size  n_charges = 1 
)
static

compute the match-odds score, a score based on the probability of getting the given number of matched peaks by chance

Parameters
[in]theoretical_spectheoretical spectrum, sorted by position
[in]matched_sizealignment between the theoretical and the experimental spectra
[in]fragment_mass_tolerancefragment mass tolerance of the alignment
[in]fragment_mass_tolerance_unit_ppmfragment mass tolerance unit of the alignment, true = ppm, false = Da
[in]is_xlink_spectrumtype of cross-link, true = cross-link, false = mono-link
[in]n_chargesnumber of considered charges in the theoretical spectrum

◆ matchOddsScoreSimpleSpec()

static double matchOddsScoreSimpleSpec ( const std::vector< SimpleTSGXLMS::SimplePeak > &  theoretical_spec,
const Size  matched_size,
double  fragment_mass_tolerance,
bool  fragment_mass_tolerance_unit_ppm,
bool  is_xlink_spectrum = false,
Size  n_charges = 1 
)
static

◆ preScore() [1/2]

static float preScore ( Size  matched_alpha,
Size  ions_alpha 
)
static

compute a simple and fast to compute pre-score for a mono-link spectrum match

Parameters
[in]matched_alphanumber of experimental peaks matched to theoretical linear ions from the alpha peptide
[in]ions_alphanumber of theoretical ions from the alpha peptide

◆ preScore() [2/2]

static float preScore ( Size  matched_alpha,
Size  ions_alpha,
Size  matched_beta,
Size  ions_beta 
)
static

compute a simple and fast to compute pre-score for a cross-link spectrum match

Parameters
[in]matched_alphanumber of experimental peaks matched to theoretical linear ions from the alpha peptide
[in]ions_alphanumber of theoretical ions from the alpha peptide
[in]matched_betanumber of experimental peaks matched to theoretical linear ions from the beta peptide
[in]ions_betanumber of theoretical ions from the beta peptide

◆ totalMatchedCurrent()

static double totalMatchedCurrent ( const std::vector< std::pair< Size, Size > > &  matched_spec_linear_alpha,
const std::vector< std::pair< Size, Size > > &  matched_spec_linear_beta,
const std::vector< std::pair< Size, Size > > &  matched_spec_xlinks_alpha,
const std::vector< std::pair< Size, Size > > &  matched_spec_xlinks_beta,
const PeakSpectrum spectrum_linear_peaks,
const PeakSpectrum spectrum_xlink_peaks 
)
static

computes sum of peak intensities of all matched peaks

Parameters
[in]matched_spec_linear_alphaalignment between linear alpha ions and linear experimental peaks
[in]matched_spec_linear_betaalignment between linear beta ions and linear experimental peaks
[in]matched_spec_xlinks_alphaalignment between xlink alpha ions and xlink experimental peaks
[in]matched_spec_xlinks_betaalignment between xlink beta ions and xlink experimental peaks
[in]spectrum_linear_peaksexperimental linear ion spectrum
[in]spectrum_xlink_peaksexperimental xlink spectrum

◆ weightedTICScore()

static double weightedTICScore ( Size  alpha_size,
Size  beta_size,
double  intsum_alpha,
double  intsum_beta,
double  total_current,
bool  type_is_cross_link 
)
static

compute the weighted total ion current score for a cross-link. Scaling changed from original xQuest.

Parameters
[in]alpha_sizesequence length of alpha peptide
[in]beta_sizesequence length of beta peptide
[in]intsum_alphaintensity sum of matched peaks from alpha peptide
[in]intsum_betaintensity sum of matched peaks from beta peptide
[in]total_currentSum of peak intensities of the experimental spectrum
[in]type_is_cross_linkType of cross-link, true = cross-link, false = mono-link
Returns
true = cross-link, false = mono-link. in case of a mono-link, beta_size and intsum_beta should be 0

◆ weightedTICScoreXQuest()

static double weightedTICScoreXQuest ( Size  alpha_size,
Size  beta_size,
double  intsum_alpha,
double  intsum_beta,
double  total_current,
bool  type_is_cross_link 
)
static

compute the weighted total ion current score for a cross-link. Reimplementation from xQuest.

Parameters
[in]alpha_sizesequence length of alpha peptide
[in]beta_sizesequence length of beta peptide
[in]intsum_alphaintensity sum of matched peaks from alpha peptide
[in]intsum_betaintensity sum of matched peaks from beta peptide
[in]total_currentsum of peak intensities of the experimental spectrum
[in]type_is_cross_linktype of cross-link, true = cross-link, false = mono-link
Returns
true = cross-link, false = mono-link. in case of a mono-link, beta_size and intsum_beta should be 0

◆ xCorrelation()

static std::vector< double > xCorrelation ( const PeakSpectrum spec1,
const PeakSpectrum spec2,
Int  maxshift,
double  tolerance 
)
static

computes a crude cross-correlation between two spectra. Crude, because it uses a static binsize based on a tolerance in Da and it uses equal intensities for all peaks

Parameters
[in]spec1first spectrum
[in]spec2second spectrum
[in]maxshiftNumber of bins, that should be considered for shifting the second spectrum. the second spectrum is shifted from -maxshift to +maxshift of tolerance bins and a correlation is computed for each position.
[in]toleranceor binsize in Da

◆ xCorrelationPrescore()

static double xCorrelationPrescore ( const PeakSpectrum spec1,
const PeakSpectrum spec2,
double  tolerance 
)
static

computes a crude dot product between two spectra. Crude, because it uses a static binsize based on a tolerance in Da and it uses equal intensities for all peaks

Parameters
[in]spec1first spectrum
[in]spec2second spectrum
[in]tolerancetolerance or binsize in Da