Trait tea_rolling::RollingValidFeature

source ·
pub trait RollingValidFeature<T: IsNone>: Vec1View<T> {
Show 16 methods // Provided methods fn ts_vsum_to<O: Vec1<U>, U>( &self, window: usize, min_periods: Option<usize>, out: Option<O::UninitRefMut<'_>>, ) -> Option<O> where T::Inner: Number, f64: Cast<U> { ... } fn ts_vsum<O: Vec1<U>, U>( &self, window: usize, min_periods: Option<usize>, ) -> O where T::Inner: Number, f64: Cast<U> { ... } fn ts_vmean_to<O: Vec1<U>, U>( &self, window: usize, min_periods: Option<usize>, out: Option<O::UninitRefMut<'_>>, ) -> Option<O> where T::Inner: Number, f64: Cast<U> { ... } fn ts_vmean<O: Vec1<U>, U>( &self, window: usize, min_periods: Option<usize>, ) -> O where T::Inner: Number, f64: Cast<U> { ... } fn ts_vewm_to<O: Vec1<U>, U>( &self, window: usize, min_periods: Option<usize>, out: Option<O::UninitRefMut<'_>>, ) -> Option<O> where T::Inner: Number, f64: Cast<U> { ... } fn ts_vewm<O: Vec1<U>, U>( &self, window: usize, min_periods: Option<usize>, ) -> O where T::Inner: Number, f64: Cast<U> { ... } fn ts_vwma_to<O: Vec1<U>, U>( &self, window: usize, min_periods: Option<usize>, out: Option<O::UninitRefMut<'_>>, ) -> Option<O> where T::Inner: Number, f64: Cast<U> { ... } fn ts_vwma<O: Vec1<U>, U>( &self, window: usize, min_periods: Option<usize>, ) -> O where T::Inner: Number, f64: Cast<U> { ... } fn ts_vstd_to<O: Vec1<U>, U>( &self, window: usize, min_periods: Option<usize>, out: Option<O::UninitRefMut<'_>>, ) -> Option<O> where T::Inner: Number, f64: Cast<U> { ... } fn ts_vstd<O: Vec1<U>, U>( &self, window: usize, min_periods: Option<usize>, ) -> O where T::Inner: Number, f64: Cast<U> { ... } fn ts_vvar_to<O: Vec1<U>, U>( &self, window: usize, min_periods: Option<usize>, out: Option<O::UninitRefMut<'_>>, ) -> Option<O> where T::Inner: Number, f64: Cast<U> { ... } fn ts_vvar<O: Vec1<U>, U>( &self, window: usize, min_periods: Option<usize>, ) -> O where T::Inner: Number, f64: Cast<U> { ... } fn ts_vskew_to<O: Vec1<U>, U>( &self, window: usize, min_periods: Option<usize>, out: Option<O::UninitRefMut<'_>>, ) -> Option<O> where T::Inner: Number, f64: Cast<U> { ... } fn ts_vskew<O: Vec1<U>, U>( &self, window: usize, min_periods: Option<usize>, ) -> O where T::Inner: Number, f64: Cast<U> { ... } fn ts_vkurt_to<O: Vec1<U>, U>( &self, window: usize, min_periods: Option<usize>, out: Option<O::UninitRefMut<'_>>, ) -> Option<O> where T::Inner: Number, f64: Cast<U> { ... } fn ts_vkurt<O: Vec1<U>, U>( &self, window: usize, min_periods: Option<usize>, ) -> O where T::Inner: Number, f64: Cast<U> { ... }
}
Expand description

Trait for rolling window operations on valid (non-None) elements.

Provided Methods§

source

fn ts_vsum_to<O: Vec1<U>, U>( &self, window: usize, min_periods: Option<usize>, out: Option<O::UninitRefMut<'_>>, ) -> Option<O>
where T::Inner: Number, f64: Cast<U>,

Calculates the rolling sum of valid elements within a window.

§Arguments
  • 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.
§Returns

A vector containing the rolling sums.

§See Also

RollingFeature::ts_sum

source

fn ts_vsum<O: Vec1<U>, U>(&self, window: usize, min_periods: Option<usize>) -> O
where T::Inner: Number, f64: Cast<U>,

Calculates the rolling sum of valid elements within a window.

§Arguments
  • 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.
§Returns

A vector containing the rolling sums.

§See Also

RollingFeature::ts_sum

source

fn ts_vmean_to<O: Vec1<U>, U>( &self, window: usize, min_periods: Option<usize>, out: Option<O::UninitRefMut<'_>>, ) -> Option<O>
where T::Inner: Number, f64: Cast<U>,

Calculates the rolling mean of valid elements within a window.

§Arguments
  • 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.
§Returns

A vector containing the rolling means.

§See Also

RollingFeature::ts_mean

source

fn ts_vmean<O: Vec1<U>, U>( &self, window: usize, min_periods: Option<usize>, ) -> O
where T::Inner: Number, f64: Cast<U>,

Calculates the rolling mean of valid elements within a window.

§Arguments
  • 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.
§Returns

A vector containing the rolling means.

§See Also

RollingFeature::ts_mean

source

fn ts_vewm_to<O: Vec1<U>, U>( &self, window: usize, min_periods: Option<usize>, out: Option<O::UninitRefMut<'_>>, ) -> Option<O>
where T::Inner: Number, f64: Cast<U>,

Calculates the exponentially weighted moving average of valid elements within a window.

§Arguments
  • 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.
§Returns

A vector containing the exponentially weighted moving averages.

§See Also

RollingFeature::ts_ewm

source

fn ts_vewm<O: Vec1<U>, U>(&self, window: usize, min_periods: Option<usize>) -> O
where T::Inner: Number, f64: Cast<U>,

Calculates the exponentially weighted moving average of valid elements within a window.

§Arguments
  • 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.
§Returns

A vector containing the exponentially weighted moving averages.

§See Also

RollingFeature::ts_ewm

source

fn ts_vwma_to<O: Vec1<U>, U>( &self, window: usize, min_periods: Option<usize>, out: Option<O::UninitRefMut<'_>>, ) -> Option<O>
where T::Inner: Number, f64: Cast<U>,

Calculates the weighted moving average of valid elements within a window.

§Arguments
  • 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.
§Returns

A vector containing the weighted moving averages.

§See Also

RollingFeature::ts_wma

source

fn ts_vwma<O: Vec1<U>, U>(&self, window: usize, min_periods: Option<usize>) -> O
where T::Inner: Number, f64: Cast<U>,

Calculates the weighted moving average of valid elements within a window.

§Arguments
  • 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.
§Returns

A vector containing the weighted moving averages.

§See Also

RollingFeature::ts_wma

source

fn ts_vstd_to<O: Vec1<U>, U>( &self, window: usize, min_periods: Option<usize>, out: Option<O::UninitRefMut<'_>>, ) -> Option<O>
where T::Inner: Number, f64: Cast<U>,

Calculates the rolling standard deviation of valid elements within a window.

§Arguments
  • 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.
§Returns

A vector containing the rolling standard deviations.

§See Also

RollingFeature::ts_std

source

fn ts_vstd<O: Vec1<U>, U>(&self, window: usize, min_periods: Option<usize>) -> O
where T::Inner: Number, f64: Cast<U>,

Calculates the rolling standard deviation of valid elements within a window.

§Arguments
  • 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.
§Returns

A vector containing the rolling standard deviations.

§See Also

RollingFeature::ts_std

source

fn ts_vvar_to<O: Vec1<U>, U>( &self, window: usize, min_periods: Option<usize>, out: Option<O::UninitRefMut<'_>>, ) -> Option<O>
where T::Inner: Number, f64: Cast<U>,

Calculates the rolling variance of valid elements within a window.

§Arguments
  • 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.
§Returns

A vector containing the rolling variances.

§See Also

RollingFeature::ts_var

source

fn ts_vvar<O: Vec1<U>, U>(&self, window: usize, min_periods: Option<usize>) -> O
where T::Inner: Number, f64: Cast<U>,

Calculates the rolling variance of valid elements within a window.

§Arguments
  • 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.
§Returns

A vector containing the rolling variances.

§See Also

RollingFeature::ts_var

source

fn ts_vskew_to<O: Vec1<U>, U>( &self, window: usize, min_periods: Option<usize>, out: Option<O::UninitRefMut<'_>>, ) -> Option<O>
where T::Inner: Number, f64: Cast<U>,

Calculates the rolling skewness of valid elements within a window.

§Arguments
  • 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.
§Returns

A vector containing the rolling skewness values.

§See Also

RollingFeature::ts_skew

source

fn ts_vskew<O: Vec1<U>, U>( &self, window: usize, min_periods: Option<usize>, ) -> O
where T::Inner: Number, f64: Cast<U>,

Calculates the rolling skewness of valid elements within a window.

§Arguments
  • 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.
§Returns

A vector containing the rolling skewness values.

§See Also

RollingFeature::ts_skew

source

fn ts_vkurt_to<O: Vec1<U>, U>( &self, window: usize, min_periods: Option<usize>, out: Option<O::UninitRefMut<'_>>, ) -> Option<O>
where T::Inner: Number, f64: Cast<U>,

Calculates the rolling kurtosis for the vector, handling None values.

§Arguments
  • 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 kurtosis values.

§See Also

ts_kurt - The version of this function that doesn’t handle None values.

source

fn ts_vkurt<O: Vec1<U>, U>( &self, window: usize, min_periods: Option<usize>, ) -> O
where T::Inner: Number, f64: Cast<U>,

Calculates the rolling kurtosis for the vector, handling None values.

§Arguments
  • 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 kurtosis values.

§See Also

ts_kurt - The version of this function that doesn’t handle None values.

Object Safety§

This trait is not object safe.

Implementors§