A Julia package for univariate interpolations.
This package is inspired by scipy.interpolate.interp1d function.
Julia 1.6.x or higher.
If you want use latest development version,
using Pkg;Pkg.add(url = "https://github.com/AtsushiSakai/Interp1d.jl.git")
You can use many kind of univariate interpolations:
using Interp1d
using PyPlot
xi = collect(0.0:10.0) # x of interpolated points
yi = exp.(-xi./3.0) # y of interpolated points
x = collect(-1.0:0.1:11.0) # sampling points
for mode in INTERP_MODE_LIST # Do interpolations for all modes.
f = interp(xi, yi, mode) # get an interpolation function
y = f.(x) # Do interpolation
plot(x, y, label=string(mode))
end
plot(xi, yi, "xr")
legend()
Details and other tips can be found in the latest documentaion: