[SciPy-User] Interpolate a list of numbers?
Anthony Palomba
apalomba at austin.rr.com
Tue Sep 13 19:22:47 EDT 2011
Just to be super clear...
Instead of using a range, a la np.linspace, I want to be able
to interpolate a list of paired tuples,
like [x1, y1, x2, y2, x3, y3, x4, y4]
Any ideas?
-ap
On Tue, Sep 13, 2011 at 5:57 PM, Anthony Palomba <apalomba at austin.rr.com>wrote:
> Hey scipyers,
>
> I have an interpolation question...
>
> I have a function that I am currently using to do interpolation.
>
> def interpmap(c, x1, y1, x2, y2, base = None):
> range1 = np.linspace(x1, y1, 20)
> range2 = np.linspace(x2, y2, 20)
> f = interpolate.interp1d(range1, range2)
> return f(c)
>
> I takes range (x1 <= y1) and maps it on to (x2 <= y2).
>
> I would like to be able to specify a list of points as
> the range. Is it possible to create a linspace from a list?
>
>
>
> Thanks,
> Anthony
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.scipy.org/pipermail/scipy-user/attachments/20110913/4bcefe80/attachment.html>
More information about the SciPy-User
mailing list