Expand description
Temporal feature extraction functions for time-series data.
All functions operate on &[f64] slices and return Vec<f64>,
using f64::NAN where values cannot be computed (e.g. boundary rows).
Functions§
- diff
- N-th order differencing.
- ewm
- Exponentially weighted mean with configurable
alpha ∈ (0, 1]. - lag
- Lag: value
offsetrows earlier. Returns NAN for firstoffsetrows. - pct_
change - Percentage change:
(values[i] - values[i-1]) / values[i-1]. First element is NAN. Returns NAN whenvalues[i-1]is zero. - rolling_
corr - Rolling Pearson correlation between two columns.
- rolling_
mean - Rolling arithmetic mean over a trailing window.
- rolling_
std - Rolling standard deviation using Welford’s online algorithm.
- zscore
- Z-score normalization:
(value - mean) / std_dev.