Method: Polars::Expr#rolling_var
- Defined in:
- lib/polars/expr.rb
permalink #rolling_var(window_size, weights: nil, min_periods: nil, center: false, ddof: 1) ⇒ Expr
Note:
This functionality is experimental and may change without it being considered a breaking change.
Note:
If you want to compute multiple aggregation statistics over the same dynamic
window, consider using group_by_rolling
this method can cache the window size
computation.
Compute a rolling variance.
A window of length window_size
will traverse the array. The values that fill
this window will (optionally) be multiplied with the weights given by the
weight
vector. The resulting values will be aggregated to their sum.
5480 5481 5482 5483 5484 5485 5486 5487 5488 5489 5490 5491 5492 |
# File 'lib/polars/expr.rb', line 5480 def rolling_var( window_size, weights: nil, min_periods: nil, center: false, ddof: 1 ) _from_rbexpr( _rbexpr.rolling_var( window_size, weights, min_periods, center, ddof ) ) end |