kind | routne | continuity | comment | alias | |
---|---|---|---|---|---|
linear | numpy.interp |
broken line | comes from numpy | ||
cubic spline | CubicSpline |
2nd derivative | |||
1D | monotone cubic spline | PchipInterpolator |
1st derivative | non-overshooting | |
non-cubic spline | make_interp_spline |
(k-1)th derivative | |||
nearest | interp1d |
none | kind='nearest', | ||
'previous', 'next' | |||||
----------------- | |||||
N-D curve | nearest, linear, spline | make_interp_spline |
(k-1)th derivative | use N-dim y array |
|
----------------- | |||||
nearest | |||||
N-D regular grid | linear | RegularGridInterpolator |
rectilinear grids | interpn |
|
splines | 2nd derivatives | ||||
monotone splines | 1st derivatives | method='pchip' | |||
----------------- | |||||
nearest | NearestNDInterpolator |
||||
N-D scattered | linear | LinearNDInterpolator |
griddata |
||
cubic (2D only) | CloughTocher2DInterpolator |
1st derivatives |
Last active
November 8, 2022 15:48
-
-
Save ev-br/fcd25570c3f332faefd521e6d3c87510 to your computer and use it in GitHub Desktop.
Recommended routines for interpolation in `scipy.interpolate`
@tupui yes, great idea! In the scipy.interpolate tutorial, which is where the canonic version of this table resides now :-).
ah yes cool. I missed/forgot that it went in.
Indeed, this was a wall of text PR, easy to miss parts of! BTW,the whole rbf section of the tutorial needs porting from rbf to rbfinterpolator. Would be even better if an rbf/rbfinterpolator user does it. Are you?
Truth to be told at the moment I am really only a user of stats.qmc
π
But agreed we should at least update the code to use RBFInterpolator
. I can do that quickly if you want.
Would be great actually!
Re stats.qmc --- this is a great piece of work, much appreciated!
Thanks π
And just opened scipy/scipy#17371
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Nice list π Maybe also add
RBFInterpolator
inN-D scattered
?