pybaselines.Baseline.corner_cutting

Baseline.corner_cutting(data, max_iter=100)[source]

Iteratively removes corner points and creates a Bezier spline from the remaining points.

Parameters:
dataarray_like, shape (N,)

The y-values of the measured data, with N data points.

max_iterint, optional

The maximum number of iterations to try to remove corner points. Default is 100. Typically all corner points are removed in 10 to 20 iterations.

Returns:
baselinenumpy.ndarray, shape (N,)

The calculated baseline.

dict

An empty dictionary, just to match the output of all other algorithms.

References

Liu, Y.J., et al. A Concise Iterative Method with Bezier Technique for Baseline Construction. Analyst, 2015, 140(23), 7984-7996.