Trait tea_rolling::RollingValidBinary

source ·
pub trait RollingValidBinary<T: IsNone>: Vec1View<T> {
    // Provided methods
    fn ts_vcov_to<O: Vec1<U>, U, V2: Vec1View<T2>, T2: IsNone>(
        &self,
        other: &V2,
        window: usize,
        min_periods: Option<usize>,
        out: Option<O::UninitRefMut<'_>>,
    ) -> Option<O>
       where T::Inner: Number,
             T2::Inner: Number,
             f64: Cast<U> { ... }
    fn ts_vcov<O: Vec1<U>, U, V2: Vec1View<T2>, T2: IsNone>(
        &self,
        other: &V2,
        window: usize,
        min_periods: Option<usize>,
    ) -> O
       where T::Inner: Number,
             T2::Inner: Number,
             f64: Cast<U> { ... }
    fn ts_vcorr_to<O: Vec1<U>, U, V2: Vec1View<T2>, T2: IsNone>(
        &self,
        other: &V2,
        window: usize,
        min_periods: Option<usize>,
        out: Option<O::UninitRefMut<'_>>,
    ) -> Option<O>
       where T::Inner: Number,
             T2::Inner: Number,
             f64: Cast<U> { ... }
    fn ts_vcorr<O: Vec1<U>, U, V2: Vec1View<T2>, T2: IsNone>(
        &self,
        other: &V2,
        window: usize,
        min_periods: Option<usize>,
    ) -> O
       where T::Inner: Number,
             T2::Inner: Number,
             f64: Cast<U> { ... }
}
Expand description

Trait for performing rolling binary operations on valid elements in vectors.

This trait provides methods for calculating rolling covariance and correlation between two vectors of potentially nullable elements.

Provided Methods§

source

fn ts_vcov_to<O: Vec1<U>, U, V2: Vec1View<T2>, T2: IsNone>( &self, other: &V2, window: usize, min_periods: Option<usize>, out: Option<O::UninitRefMut<'_>>, ) -> Option<O>
where T::Inner: Number, T2::Inner: Number, f64: Cast<U>,

Calculates the rolling covariance between two vectors.

§Arguments
  • other - The other vector to calculate covariance with.
  • window - The size of the rolling window.
  • min_periods - The minimum number of observations in window required to have a value.
  • out - Optional output buffer to store the results.
§Returns

A vector containing the rolling covariance values.

source

fn ts_vcov<O: Vec1<U>, U, V2: Vec1View<T2>, T2: IsNone>( &self, other: &V2, window: usize, min_periods: Option<usize>, ) -> O
where T::Inner: Number, T2::Inner: Number, f64: Cast<U>,

Calculates the rolling covariance between two vectors.

§Arguments
  • other - The other vector to calculate covariance with.
  • window - The size of the rolling window.
  • min_periods - The minimum number of observations in window required to have a value.
  • out - Optional output buffer to store the results.
§Returns

A vector containing the rolling covariance values.

source

fn ts_vcorr_to<O: Vec1<U>, U, V2: Vec1View<T2>, T2: IsNone>( &self, other: &V2, window: usize, min_periods: Option<usize>, out: Option<O::UninitRefMut<'_>>, ) -> Option<O>
where T::Inner: Number, T2::Inner: Number, f64: Cast<U>,

Calculates the rolling correlation between two vectors.

§Arguments
  • other - The other vector to calculate correlation with.
  • window - The size of the rolling window.
  • min_periods - The minimum number of observations in window required to have a value.
  • out - Optional output buffer to store the results.
§Returns

A vector containing the rolling correlation values.

source

fn ts_vcorr<O: Vec1<U>, U, V2: Vec1View<T2>, T2: IsNone>( &self, other: &V2, window: usize, min_periods: Option<usize>, ) -> O
where T::Inner: Number, T2::Inner: Number, f64: Cast<U>,

Calculates the rolling correlation between two vectors.

§Arguments
  • other - The other vector to calculate correlation with.
  • window - The size of the rolling window.
  • min_periods - The minimum number of observations in window required to have a value.
  • out - Optional output buffer to store the results.
§Returns

A vector containing the rolling correlation values.

Object Safety§

This trait is not object safe.

Implementors§

source§

impl<T: IsNone, I: Vec1View<T>> RollingValidBinary<T> for I