MovingAverageThreshold Filter¶
-
template<typename T, size_t N, T Threshold>
struct MovingAverageThreshold¶ Filter using moving average threshold.
This stateful filter maintains a moving average over a sliding window and propagates changes only when the average exceeds the specified threshold.
- Since
v0.1.0
// Example: Moving average with window of 5, threshold of 50 Signal<float, 10, MovingAverageThreshold<float, 5, 50>> sensor(0.0);Note
Stateful filter. Moving average over sliding window.
Warning
Only accepts arithmetic types (integral and floating-point).
Window size
Nmust be greater than 0.
See Also¶
Statistical Filters - Overview