scipy.interpolate.PchipInterpolator¶
- class scipy.interpolate.PchipInterpolator(x, y, axis=0)[source]¶
PCHIP 1-d monotonic cubic interpolation
x and y are arrays of values used to approximate some function f, with y = f(x). The interpolant uses monotonic cubic splines to find the value of new points.
Parameters : x : ndarray
A 1-D array of monotonically increasing real values. x cannot include duplicate values (otherwise f is overspecified)
y : ndarray
A 1-D array of real values. y‘s length along the interpolation axis must be equal to the length of x.
axis : int, optional
Axis in the yi array corresponding to the x-coordinate values.
Notes
Assumes x is sorted in monotonic order (e.g. x[1] > x[0]).
Methods
__call__(x) Evaluate the interpolant append(xi, yi[, order]) Append a single point with derivatives to the PiecewisePolynomial derivative(x[, der]) Evaluate one derivative of the polynomial at the point x derivatives(x[, der]) Evaluate many derivatives of the polynomial at the point x extend(xi, yi[, orders]) Extend the PiecewisePolynomial by a list of points