croissance.estimation.smoothing.segments module#
- croissance.estimation.smoothing.segments.segment_by_std_dev(series, increment=2, maximum=20)[source]#
Divides a series into segments, minimizing standard deviation over window size. Windows are of varying size from increment to maximum * increment at each offset increment within the series.
- croissance.estimation.smoothing.segments.segment_points(series, segments)[source]#
Picks knot points for an interpolating spline along a series of segments according to these rules:
For small segments, add a knot in the center of the segment
For medium-sized segments, add a knot near the beginning and end of the segment
For large segments, add a knot a knot near the beginning and end of the segment, and one in the center.