Interpolation model for transformations. More...
#include <OpenMS/ANALYSIS/MAPMATCHING/TransformationModelInterpolated.h>
Classes | |
| class | Interpolator | 
| The class defines a generic interpolation technique used in the TransformationModelInterpolated.  More... | |
Public Member Functions | |
| TransformationModelInterpolated (const DataPoints &data, const Param ¶ms) | |
| Constructor.  More... | |
| TransformationModelInterpolated (const std::vector< std::pair< double, double >> &data, const Param ¶ms, bool preprocess) | |
| ~TransformationModelInterpolated () override | |
| Destructor.  More... | |
| double | evaluate (double value) const override | 
| Evaluate the interpolation model at the given value.  More... | |
  Public Member Functions inherited from TransformationModel | |
| TransformationModel () | |
| Constructor.  More... | |
| TransformationModel (const TransformationModel::DataPoints &, const Param &) | |
| virtual | ~TransformationModel () | 
| Destructor.  More... | |
| virtual void | weightData (DataPoints &data) | 
| Weight the data by the given weight function.  More... | |
| virtual void | unWeightData (DataPoints &data) | 
| Unweight the data by the given weight function.  More... | |
| bool | checkValidWeight (const String &weight, const std::vector< String > &valid_weights) const | 
| Check for a valid weighting function string.  More... | |
| double | checkDatumRange (const double &datum, const double &datum_min, const double &datum_max) | 
| Check that the datum is within the valid min and max bounds.  More... | |
| double | weightDatum (const double &datum, const String &weight) const | 
| Weight the data according to the weighting function.  More... | |
| double | unWeightDatum (const double &datum, const String &weight) const | 
| Apply the reverse of the weighting function to the data.  More... | |
| const Param & | getParameters () const | 
| Gets the (actual) parameters.  More... | |
| std::vector< String > | getValidXWeights () const | 
| Returns a list of valid x weight function strings.  More... | |
| std::vector< String > | getValidYWeights () const | 
| Returns a list of valid y weight function strings.  More... | |
Static Public Member Functions | |
| static void | getDefaultParameters (Param ¶ms) | 
| Gets the default parameters.  More... | |
  Static Public Member Functions inherited from TransformationModel | |
| static void | getDefaultParameters (Param ¶ms) | 
| Gets the default parameters.  More... | |
Private Member Functions | |
| void | preprocessDataPoints_ (const DataPoints &data) | 
| Preprocesses the incoming data and fills the (private) vectors x_ and y_.  More... | |
| void | preprocessDataPoints_ (const std::vector< std::pair< double, double >> &data) | 
| Preprocesses the incoming data and fills the (private) vectors x_ and y_.  More... | |
Private Attributes | |
| std::vector< double > | x_ | 
| Data coordinates x.  More... | |
| std::vector< double > | y_ | 
| Data coordinates y.  More... | |
| Interpolator * | interp_ | 
| Interpolation function.  More... | |
| TransformationModelLinear * | lm_front_ | 
| Linear model for extrapolation (front)  More... | |
| TransformationModelLinear * | lm_back_ | 
| Linear model for extrapolation (back)  More... | |
Additional Inherited Members | |
  Public Types inherited from TransformationModel | |
| typedef std::vector< DataPoint > | DataPoints | 
| Vector of coordinate pairs.  More... | |
  Protected Attributes inherited from TransformationModel | |
| Param | params_ | 
| Parameters.  More... | |
| String | x_weight_ | 
| x weighting  More... | |
| double | x_datum_min_ | 
| double | x_datum_max_ | 
| String | y_weight_ | 
| y weighting  More... | |
| double | y_datum_min_ | 
| double | y_datum_max_ | 
| bool | weighting_ | 
Interpolation model for transformations.
Between the data points, the interpolation uses the neighboring points to interpolate. The following interpolation methods are available:
Outside the range spanned by the points, we extrapolate using one of the following methods:
| TransformationModelInterpolated | ( | const DataPoints & | data, | 
| const Param & | params | ||
| ) | 
Constructor.
| data | The known data points. | 
| params | Param object holding information on which model to choose. | 
| IllegalArgument | is thrown if there are not enough data points or if an unknown interpolation type is given. | 
| TransformationModelInterpolated | ( | const std::vector< std::pair< double, double >> & | data, | 
| const Param & | params, | ||
| bool | preprocess | ||
| ) | 
      
  | 
  override | 
Destructor.
      
  | 
  overridevirtual | 
Evaluate the interpolation model at the given value.
| value | The position where the interpolation should be evaluated. | 
Reimplemented from TransformationModel.
      
  | 
  static | 
Gets the default parameters.
      
  | 
  private | 
Preprocesses the incoming data and fills the (private) vectors x_ and y_.
      
  | 
  private | 
Preprocesses the incoming data and fills the (private) vectors x_ and y_.
      
  | 
  private | 
Interpolation function.
      
  | 
  private | 
Linear model for extrapolation (back)
      
  | 
  private | 
Linear model for extrapolation (front)
      
  | 
  private | 
Data coordinates x.
      
  | 
  private | 
Data coordinates y.