Skip to main content

monotone_slopes

Function monotone_slopes 

Source
pub fn monotone_slopes(points: &[Point]) -> Vec<f32>
Expand description

The slope at each of points (in order, with growing x) of a curve that never swings past them: Fritsch-Carlson, with a harmonic mean. Charts and curve editors share it so that a curve reads the same in both. Fewer than two points have no slope to speak of, so they get zeros.