Data structure for spline interpolation of MS1 spectra. More...
#include <OpenMS/FILTERING/DATAREDUCTION/SplineSpectrum.h>
Classes | |
class | Navigator |
iterator class for access of spline packages More... | |
Public Member Functions | |
SplineSpectrum (const std::vector< double > &mz, const std::vector< double > &intensity) | |
constructor taking two vectors (and an optional scaling factor for the m/z step width) More... | |
SplineSpectrum (const std::vector< double > &mz, const std::vector< double > &intensity, double scaling) | |
SplineSpectrum (MSSpectrum &raw_spectrum) | |
constructor taking an MSSpectrum (and an optional scaling factor for the m/z step width) More... | |
SplineSpectrum (MSSpectrum &raw_spectrum, double scaling) | |
~SplineSpectrum () | |
destructor More... | |
double | getMzMin () const |
returns the minimum m/z of the spectrum More... | |
double | getMzMax () const |
returns the maximum m/z of the spectrum More... | |
size_t | getSplineCount () const |
SplineSpectrum::Navigator | getNavigator () |
returns an iterator for access of spline packages More... | |
Private Member Functions | |
SplineSpectrum () | |
hide default C'tor More... | |
void | init_ (const std::vector< double > &mz, const std::vector< double > &intensity, double scaling) |
section common for all constructors More... | |
Private Attributes | |
double | mz_min_ |
m/z limits of the spectrum More... | |
double | mz_max_ |
std::vector< SplinePackage > | packages_ |
set of spline packages each interpolating in a certain m/z range More... | |
Data structure for spline interpolation of MS1 spectra.
The data structure consists of a set of splines, each interpolating the MS1 spectrum in a certain m/z range. Between these splines no raw data points exist and the spectrum intensity is identical to zero.
SplineSpectrum | ( | const std::vector< double > & | mz, |
const std::vector< double > & | intensity | ||
) |
constructor taking two vectors (and an optional scaling factor for the m/z step width)
SplineSpectrum | ( | const std::vector< double > & | mz, |
const std::vector< double > & | intensity, | ||
double | scaling | ||
) |
SplineSpectrum | ( | MSSpectrum & | raw_spectrum | ) |
constructor taking an MSSpectrum (and an optional scaling factor for the m/z step width)
SplineSpectrum | ( | MSSpectrum & | raw_spectrum, |
double | scaling | ||
) |
~SplineSpectrum | ( | ) |
destructor
|
private |
hide default C'tor
double getMzMax | ( | ) | const |
returns the maximum m/z of the spectrum
Referenced by SpectraMerger::averageProfileSpectra_().
double getMzMin | ( | ) | const |
returns the minimum m/z of the spectrum
Referenced by SpectraMerger::averageProfileSpectra_().
SplineSpectrum::Navigator getNavigator | ( | ) |
returns an iterator for access of spline packages
Will throw an exception if no packages were found during construction. Check using getSplineCount().
Make sure that the underlying SplineSpectrum does not run out-of-scope since the Navigator relies on its data.
Exception::InvalidSize | if packages is empty |
Referenced by SpectraMerger::averageProfileSpectra_().
size_t getSplineCount | ( | ) | const |
Get number of spline packages found during initialization
Note that this function should be called right after the C'tor to ensure the spectrum has some usable data to work on. In case there are no packages, a subsequent call to getNavigator() will throw an exception.
|
private |
section common for all constructors
|
private |
|
private |
m/z limits of the spectrum
|
private |
set of spline packages each interpolating in a certain m/z range
OpenMS / TOPP release 2.3.0 | Documentation generated on Tue Jan 9 2018 18:22:13 using doxygen 1.8.13 |