OpenMS
|
Functions | |
bool | integrateWindow (const OpenSwath::SpectrumPtr &spectrum, double &mz, double &im, double &intensity, const RangeMZ &mz_range, const RangeMobility &im_range, bool centroided=false) |
Helper functions for the DIA scoring of OpenSWATH. More... | |
bool | integrateWindow (const SpectrumSequence &spectrum, double &mz, double &im, double &intensity, const RangeMZ &mz_range, const RangeMobility &im_range, bool centroided=false) |
Integrate intensity in SpectrumSequence in range mz_range (and im_range if defined) returning the intensity-weighted m/z and im values as well as the total intensity. More... | |
void | integrateWindows (const OpenSwath::SpectrumPtr &spectrum, const std::vector< double > &windows_center, double width, std::vector< double > &integrated_windows_intensity, std::vector< double > &integrated_windows_mz, std::vector< double > &integrated_windows_im, const RangeMobility &im_range, bool remove_zero=false) |
Integrate intensities in a spectrum in range im_range (if defined) for multiple windows. More... | |
void | integrateWindows (const SpectrumSequence &spectrum, const std::vector< double > &windows_center, double width, std::vector< double > &integrated_windows_intensity, std::vector< double > &integrated_windows_mz, std::vector< double > &integrated_windows_im, const RangeMobility &im_range, bool remove_zero=false) |
Integrate intensities of a SpectrumSequence in range im_range (if defined) for multiple windows. More... | |
void | adjustExtractionWindow (double &right, double &left, const double &mz_extract_window, const bool &mz_extraction_ppm) |
Adjust left/right window based on window and whether its ppm or not. More... | |
void | getBYSeries (const AASequence &a, std::vector< double > &bseries, std::vector< double > &yseries, TheoreticalSpectrumGenerator const *g, int charge=1) |
compute the b and y series masses for a given AASequence More... | |
void | getTheorMasses (const AASequence &a, std::vector< double > &masses, TheoreticalSpectrumGenerator const *g, int charge=1) |
for SWATH – get the theoretical b and y series masses for a sequence More... | |
void | getAveragineIsotopeDistribution (const double product_mz, std::vector< std::pair< double, double > > &isotopes_spec, const int charge=1, const int nr_isotopes=4, const double mannmass=1.00048) |
get averagine distribution given mass More... | |
void | simulateSpectrumFromAASequence (const AASequence &aa, std::vector< double > &first_isotope_masses, std::vector< std::pair< double, double > > &isotope_masses, TheoreticalSpectrumGenerator const *g, int charge=1) |
simulate spectrum from AASequence More... | |
void | addPreisotopeWeights (const std::vector< double > &first_isotope_masses, std::vector< std::pair< double, double > > &isotope_spec, UInt nr_peaks=2, double pre_isotope_peaks_weight=-0.5, double mannmass=1.000482, int charge=1) |
add (potentially negative) pre-isotope weights to spectrum More... | |
void | addPreisotopeWeights (double mz, std::vector< std::pair< double, double > > &isotope_spec, UInt nr_peaks=2, double pre_isotope_peaks_weight=-0.5, double mannmass=1.000482, int charge=1) |
add negative pre-isotope weights to spectrum More... | |
void | addIsotopes2Spec (const std::vector< std::pair< double, double > > &spec, std::vector< std::pair< double, double > > &isotope_masses, Size nr_isotopes, int charge=1) |
void | addSinglePeakIsotopes2Spec (double mz, double ity, std::vector< std::pair< double, double > > &isotope_masses, Size nr_isotopes, int charge) |
void | sortByFirst (std::vector< std::pair< double, double > > &tmp) |
sorts vector of pairs by first More... | |
void | extractFirst (const std::vector< std::pair< double, double > > &peaks, std::vector< double > &mass) |
extract first from vector of pairs More... | |
void | extractSecond (const std::vector< std::pair< double, double > > &peaks, std::vector< double > &mass) |
extract second from vector of pairs More... | |
RangeMZ | createMZRangePPM (double mz_ref, double dia_extraction_window, const bool ppm) |
optionally convert a DIA extraction window from ppm to m/z More... | |
void | integrateWindow_ (const OpenSwath::SpectrumPtr &spectrum, double &mz, double &im, double &intensity, const RangeMZ &mz_range, const RangeMobility &im_range, bool centroided) |
Helper function for integrating a spectrum. More... | |
void OpenMS::DIAHelpers::addIsotopes2Spec | ( | const std::vector< std::pair< double, double > > & | spec, |
std::vector< std::pair< double, double > > & | isotope_masses, | ||
Size | nr_isotopes, | ||
int | charge = 1 |
||
) |
given an experimental spectrum, add averagine isotope pattern for every peak. Old + new peaks are pushed to isotopeMasses
void OpenMS::DIAHelpers::addPreisotopeWeights | ( | const std::vector< double > & | first_isotope_masses, |
std::vector< std::pair< double, double > > & | isotope_spec, | ||
UInt | nr_peaks = 2 , |
||
double | pre_isotope_peaks_weight = -0.5 , |
||
double | mannmass = 1.000482 , |
||
int | charge = 1 |
||
) |
add (potentially negative) pre-isotope weights to spectrum
void OpenMS::DIAHelpers::addPreisotopeWeights | ( | double | mz, |
std::vector< std::pair< double, double > > & | isotope_spec, | ||
UInt | nr_peaks = 2 , |
||
double | pre_isotope_peaks_weight = -0.5 , |
||
double | mannmass = 1.000482 , |
||
int | charge = 1 |
||
) |
add negative pre-isotope weights to spectrum
void OpenMS::DIAHelpers::addSinglePeakIsotopes2Spec | ( | double | mz, |
double | ity, | ||
std::vector< std::pair< double, double > > & | isotope_masses, | ||
Size | nr_isotopes, | ||
int | charge | ||
) |
given a peak of experimental mz and intensity, add averagine isotope pattern to a "spectrum". Old + new peaks are pushed to isotopeMasses
void OpenMS::DIAHelpers::adjustExtractionWindow | ( | double & | right, |
double & | left, | ||
const double & | mz_extract_window, | ||
const bool & | mz_extraction_ppm | ||
) |
Adjust left/right window based on window and whether its ppm or not.
RangeMZ OpenMS::DIAHelpers::createMZRangePPM | ( | double | mz_ref, |
double | dia_extraction_window, | ||
const bool | ppm | ||
) |
optionally convert a DIA extraction window from ppm to m/z
mz_ref | Extraction window center |
dia_extraction_window | How wide the extraction window is total (can be in m/z or ppm) |
ppm | Is extraction window is in ppm? |
void OpenMS::DIAHelpers::extractFirst | ( | const std::vector< std::pair< double, double > > & | peaks, |
std::vector< double > & | mass | ||
) |
extract first from vector of pairs
void OpenMS::DIAHelpers::extractSecond | ( | const std::vector< std::pair< double, double > > & | peaks, |
std::vector< double > & | mass | ||
) |
extract second from vector of pairs
void OpenMS::DIAHelpers::getAveragineIsotopeDistribution | ( | const double | product_mz, |
std::vector< std::pair< double, double > > & | isotopes_spec, | ||
const int | charge = 1 , |
||
const int | nr_isotopes = 4 , |
||
const double | mannmass = 1.00048 |
||
) |
get averagine distribution given mass
void OpenMS::DIAHelpers::getBYSeries | ( | const AASequence & | a, |
std::vector< double > & | bseries, | ||
std::vector< double > & | yseries, | ||
TheoreticalSpectrumGenerator const * | g, | ||
int | charge = 1 |
||
) |
compute the b and y series masses for a given AASequence
void OpenMS::DIAHelpers::getTheorMasses | ( | const AASequence & | a, |
std::vector< double > & | masses, | ||
TheoreticalSpectrumGenerator const * | g, | ||
int | charge = 1 |
||
) |
for SWATH – get the theoretical b and y series masses for a sequence
bool OpenMS::DIAHelpers::integrateWindow | ( | const OpenSwath::SpectrumPtr & | spectrum, |
double & | mz, | ||
double & | im, | ||
double & | intensity, | ||
const RangeMZ & | mz_range, | ||
const RangeMobility & | im_range, | ||
bool | centroided = false |
||
) |
Helper functions for the DIA scoring of OpenSWATH.
Integrate intensity in a spectrum from in mz_range
(and im_range
if defined) returning the intensity-weighted m/z and im values as well as the total intensity.
mz
and im
will be set to -1 and intensity to 0 bool OpenMS::DIAHelpers::integrateWindow | ( | const SpectrumSequence & | spectrum, |
double & | mz, | ||
double & | im, | ||
double & | intensity, | ||
const RangeMZ & | mz_range, | ||
const RangeMobility & | im_range, | ||
bool | centroided = false |
||
) |
Integrate intensity in SpectrumSequence in range mz_range
(and im_range
if defined) returning the intensity-weighted m/z and im values as well as the total intensity.
mz
and im
will be set to -1 and intensity to 0 void OpenMS::DIAHelpers::integrateWindow_ | ( | const OpenSwath::SpectrumPtr & | spectrum, |
double & | mz, | ||
double & | im, | ||
double & | intensity, | ||
const RangeMZ & | mz_range, | ||
const RangeMobility & | im_range, | ||
bool | centroided | ||
) |
Helper function for integrating a spectrum.
void OpenMS::DIAHelpers::integrateWindows | ( | const OpenSwath::SpectrumPtr & | spectrum, |
const std::vector< double > & | windows_center, | ||
double | width, | ||
std::vector< double > & | integrated_windows_intensity, | ||
std::vector< double > & | integrated_windows_mz, | ||
std::vector< double > & | integrated_windows_im, | ||
const RangeMobility & | im_range, | ||
bool | remove_zero = false |
||
) |
Integrate intensities in a spectrum in range im_range
(if defined) for multiple windows.
spectrum | Input spectrum | |
windows_center | Center locations of the windows. | |
width | Width of the windows across m/z | |
[out] | integrated_windows_intensity | Integrated intensity for each window |
[out] | integrated_windows_mz | Integrated intensity-weighted m/z for each window |
[out] | integrated_windows_im | Integrated intensity-weighted im for each window |
im_range | is the range of the IM dimension (if defined) | |
remove_zero | Remove zero intensity windows? |
void OpenMS::DIAHelpers::integrateWindows | ( | const SpectrumSequence & | spectrum, |
const std::vector< double > & | windows_center, | ||
double | width, | ||
std::vector< double > & | integrated_windows_intensity, | ||
std::vector< double > & | integrated_windows_mz, | ||
std::vector< double > & | integrated_windows_im, | ||
const RangeMobility & | im_range, | ||
bool | remove_zero = false |
||
) |
Integrate intensities of a SpectrumSequence in range im_range
(if defined) for multiple windows.
spectrum | Input spectrum | |
windows_center | Center locations of the windows. | |
width | Width of the windows across m/z | |
[out] | integrated_windows_intensity | Integrated intensity for each window |
[out] | integrated_windows_mz | Integrated intensity-weighted m/z for each window |
[out] | integrated_windows_im | Integrated intensity-weighted im for each window |
im_range | is the range of the IM dimension (if defined) | |
remove_zero | Remove zero intensity windows? |
void OpenMS::DIAHelpers::simulateSpectrumFromAASequence | ( | const AASequence & | aa, |
std::vector< double > & | first_isotope_masses, | ||
std::vector< std::pair< double, double > > & | isotope_masses, | ||
TheoreticalSpectrumGenerator const * | g, | ||
int | charge = 1 |
||
) |
simulate spectrum from AASequence
void OpenMS::DIAHelpers::sortByFirst | ( | std::vector< std::pair< double, double > > & | tmp | ) |
sorts vector of pairs by first