Trait Interp1DStrategyBuilder

Source
pub trait Interp1DStrategyBuilder<Sd, Sx, D>
where Sd: Data, Sd::Elem: Num + Debug + Send, Sx: Data<Elem = Sd::Elem>, D: Dimension, Self: Sized,
{ type FinishedStrat: Interp1DStrategy<Sd, Sx, D>; const MINIMUM_DATA_LENGHT: usize; // Required method fn build<Sx2>( self, x: &ArrayBase<Sx2, Ix1>, data: &ArrayBase<Sd, D>, ) -> Result<Self::FinishedStrat, BuilderError> where Sx2: Data<Elem = Sd::Elem>; }

Required Associated Constants§

Required Associated Types§

Required Methods§

Source

fn build<Sx2>( self, x: &ArrayBase<Sx2, Ix1>, data: &ArrayBase<Sd, D>, ) -> Result<Self::FinishedStrat, BuilderError>
where Sx2: Data<Elem = Sd::Elem>,

initialize the strategy by validating data and possibly calculating coefficients This method is called in Interp1DBuilder::build

When this method is called by Interp1DBuilder the following properties are guaranteed:

  • x is strictly monotonically rising
  • the lenght of x equals the lenght of the data Axis 0
  • the lenght is at least MINIMUM_DATA_LENGHT
  • Interpolation will happen along axis 0

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§

Source§

impl<Sd, Sx, D> Interp1DStrategyBuilder<Sd, Sx, D> for CubicSpline<Sd::Elem, D>
where Sd: Data, Sd::Elem: SplineNum, Sx: Data<Elem = Sd::Elem>, D: Dimension + RemoveAxis,

Source§

impl<Sd, Sx, D> Interp1DStrategyBuilder<Sd, Sx, D> for Linear
where Sd: Data, Sd::Elem: Num + PartialOrd + NumCast + Copy + Debug + Sub + Send, Sx: Data<Elem = Sd::Elem>, D: Dimension + RemoveAxis,