pub fn dewindow_precipitation(
current_mm: &[f64],
hour: i64,
previous_mm: Option<&[f64]>,
previous_hour: Option<i64>,
window_hours: i64,
) -> Result<Vec<f64>>Available on crate feature
encoder only.Expand description
Mean rate (mm/h) over the step ending at hour, from totals in mm
accumulated since the start of a window that resets every window_hours
(the NAM’s APCP: 0-5 hour acc, 12-13 hour acc).
The fourth arrival shape, and deaverage_precipitation without its
scaling: a frame is already the millimetres since its window’s start, so
it is differenced as it is against the previous frame of the same
window, and the window’s first frame against zero. The rate divisor is
the interval the difference spans. Mirrors dewindow_precipitation in
xuebuild/derive.py, subtraction for subtraction.