| OpenMS 2.5.0

Public Types | Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
ContinuousWaveletTransform Class Reference

This class is the base class of the continuous wavelet transformation. More...

`#include <OpenMS/TRANSFORMATIONS/RAW2PEAK/ContinuousWaveletTransform.h>`

Inheritance diagram for ContinuousWaveletTransform:

## Public Types

typedef std::vector< Peak1D >::const_iterator | PeakConstIterator
| Raw data const iterator type. More...

## Public Member Functions

| ContinuousWaveletTransform ()
| Constructor. More...
virtual | ~ContinuousWaveletTransform ()
| Destructor. More...
const std::vector< Peak1D > & | getSignal () const
| Non-mutable access to the wavelet transform of the signal. More...
std::vector< Peak1D > & | getSignal ()
| Mutable access to the wavelet transform of the signal. More...
void | setSignal (const std::vector< Peak1D > &signal)
| Mutable access to the wavelet transform of the signal. More...
const std::vector< double > & | getWavelet () const
| Non-mutable access to the wavelet. More...
std::vector< double > & | getWavelet ()
| Mutable access to the wavelet. More...
void | setWavelet (const std::vector< double > &wavelet)
| Mutable access to the signal. More...
double | getScale () const
double & | getScale ()
| Mutable access to the spacing of raw data. More...
void | setScale (double scale)
| Mutable access to the spacing of raw data. More...
double | getSpacing () const
double & | getSpacing ()
| Mutable access to the spacing of raw data. More...
void | setSpacing (double spacing)
| Mutable access to the spacing of raw data. More...
SignedSize | getLeftPaddingIndex () const
| Non-mutable access to the position where the signal starts (in the interval [0,end_left_padding_) are the padded zeros) More...
SignedSize & | getLeftPaddingIndex ()
| Mutable access to the position where the signal starts. More...
void | setLeftPaddingIndex (const SignedSize end_left_padding)
| Mutable access to position where the signal starts. More...
SignedSize | getRightPaddingIndex () const
| Non-mutable access to the position where the signal ends (in the interval (begin_right_padding_,end] are the padded zeros) More...
SignedSize & | getRightPaddingIndex ()
| Mutable access to the position where the signal starts. More...
void | setRightPaddingIndex (const SignedSize begin_right_padding)
| Mutable access to position where the signal starts. More...
SignedSize | getSignalLength () const
| Non-mutable access to signal length [end_left_padding,begin_right_padding]. More...
SignedSize & | getSignalLength ()
| Mutable access to signal length [end_left_padding,begin_right_padding]. More...
void | setSignalLength (const SignedSize signal_length)
| Mutable access to signal length [end_left_padding,begin_right_padding]. More...
int | getSize () const
| Non-mutable access to signal length including padded zeros [0,end]. More...
virtual void | init (double scale, double spacing)
| Perform possibly necessary preprocessing steps, like tabulating the Wavelet. More...
double | operator[] (unsigned int i)
| Yields the signal (intensity) at position i. More...
double | operator[] (unsigned int i) const

## Protected Member Functions

template<typename InputPeakIterator >
double | getInterpolatedValue_ (double x, InputPeakIterator it_left)

## Protected Attributes

std::vector< Peak1D > | signal_
| The transformed signal. More...
std::vector< double > | wavelet_
| The pre-tabulated wavelet used for the transform. More...
double | scale_
| Spacing and scale of the wavelet and length of the signal. More...
double | spacing_
SignedSize | signal_length_
SignedSize | end_left_padding_
SignedSize | begin_right_padding_

## Detailed Description

This class is the base class of the continuous wavelet transformation.

## Member Typedef Documentation

## ◆ PeakConstIterator

typedef std::vector<Peak1D>::const_iterator PeakConstIterator

Raw data const iterator type.

## Constructor & Destructor Documentation

## ◆ ContinuousWaveletTransform()

ContinuousWaveletTransform | ( |  | ) |

inline

Constructor.

## ◆ ~ContinuousWaveletTransform()

virtual ~ContinuousWaveletTransform | ( |  | ) |

inline virtual

Destructor.

## Member Function Documentation

## ◆ getInterpolatedValue_()

double getInterpolatedValue_ | ( | double | x,
|  | InputPeakIterator | it_left
| ) |  |

inline protected

## ◆ getLeftPaddingIndex() [1/2]

SignedSize getLeftPaddingIndex | ( |  | ) | const

inline

Non-mutable access to the position where the signal starts (in the interval [0,end_left_padding_) are the padded zeros)

## ◆ getLeftPaddingIndex() [2/2]

SignedSize& getLeftPaddingIndex | ( |  | ) |

inline

Mutable access to the position where the signal starts.

## ◆ getRightPaddingIndex() [1/2]

SignedSize getRightPaddingIndex | ( |  | ) | const

inline

Non-mutable access to the position where the signal ends (in the interval (begin_right_padding_,end] are the padded zeros)

## ◆ getRightPaddingIndex() [2/2]

SignedSize& getRightPaddingIndex | ( |  | ) |

inline

Mutable access to the position where the signal starts.

## ◆ getScale() [1/2]

double getScale | ( |  | ) | const

inline

## ◆ getScale() [2/2]

double& getScale | ( |  | ) |

inline

Mutable access to the spacing of raw data.

## ◆ getSignal() [1/2]

const std::vector<Peak1D>& getSignal | ( |  | ) | const

inline

Non-mutable access to the wavelet transform of the signal.

## ◆ getSignal() [2/2]

std::vector<Peak1D>& getSignal | ( |  | ) |

inline

Mutable access to the wavelet transform of the signal.

## ◆ getSignalLength() [1/2]

SignedSize getSignalLength | ( |  | ) | const

inline

Non-mutable access to signal length [end_left_padding,begin_right_padding].

## ◆ getSignalLength() [2/2]

SignedSize& getSignalLength | ( |  | ) |

inline

Mutable access to signal length [end_left_padding,begin_right_padding].

## ◆ getSize()

int getSize | ( |  | ) | const

inline

Non-mutable access to signal length including padded zeros [0,end].

## ◆ getSpacing() [1/2]

double getSpacing | ( |  | ) | const

inline

## ◆ getSpacing() [2/2]

double& getSpacing | ( |  | ) |

inline

Mutable access to the spacing of raw data.

## ◆ getWavelet() [1/2]

const std::vector<double>& getWavelet | ( |  | ) | const

inline

Non-mutable access to the wavelet.

## ◆ getWavelet() [2/2]

std::vector<double>& getWavelet | ( |  | ) |

inline

Mutable access to the wavelet.

## ◆ init()

virtual void init | ( | double | scale,
|  | double | spacing
| ) |  |

virtual

Perform possibly necessary preprocessing steps, like tabulating the Wavelet.

Reimplemented in ContinuousWaveletTransformNumIntegration.

## ◆ operator[]() [1/2]

double operator[] | ( | unsigned int | i | ) |

inline

Yields the signal (intensity) at position i.

## ◆ operator[]() [2/2]

double operator[] | ( | unsigned int | i | ) | const

inline

## ◆ setLeftPaddingIndex()

void setLeftPaddingIndex | ( | const SignedSize | end_left_padding | ) |

inline

Mutable access to position where the signal starts.

## ◆ setRightPaddingIndex()

void setRightPaddingIndex | ( | const SignedSize | begin_right_padding | ) |

inline

Mutable access to position where the signal starts.

## ◆ setScale()

void setScale | ( | double | scale | ) |

inline

Mutable access to the spacing of raw data.

## ◆ setSignal()

void setSignal | ( | const std::vector< Peak1D > & | signal | ) |

inline

Mutable access to the wavelet transform of the signal.

## ◆ setSignalLength()

void setSignalLength | ( | const SignedSize | signal_length | ) |

inline

Mutable access to signal length [end_left_padding,begin_right_padding].

## ◆ setSpacing()

void setSpacing | ( | double | spacing | ) |

inline

Mutable access to the spacing of raw data.

## ◆ setWavelet()

void setWavelet | ( | const std::vector< double > & | wavelet | ) |

inline

Mutable access to the signal.

## Member Data Documentation

## ◆ begin_right_padding_

SignedSize begin_right_padding_

protected

## ◆ end_left_padding_

SignedSize end_left_padding_

protected

We often have to pad the transform at the left and right with zeros. Since we don't want to iterate over those as well, we have to store their positions.

## ◆ scale_

double scale_

protected

Spacing and scale of the wavelet and length of the signal.

## ◆ signal_

std::vector<Peak1D> signal_

protected

The transformed signal.

## ◆ signal_length_

SignedSize signal_length_

protected

## ◆ spacing_

double spacing_

protected

## ◆ wavelet_

std::vector<double> wavelet_

protected

The pre-tabulated wavelet used for the transform.