[SciPy-user] fitting a parametric spline from a set of 2D points.

Anne Archibald peridot.faceted at gmail.com
Mon Mar 10 14:37:14 EDT 2008


On 10/03/2008, LB <berthe.loic at gmail.com> wrote:

>  I've got a set of 2D points (~ 200 points) and I would like to fit a
>  parametric spline with a limited number of control points (~ 10).
>  These points can be seen a measures and contain an intrinsic error, so
>  I would like to minimize the distance between theses points and the
>  spline.
>
>  Is there any tool in scipy which could help me in this task ?
>  Otherwise, does someone know about an external library wich could
>  help ?

scipy.interpolate.splprep is designed to do exactly this. It is based
on FORTRAN code from FITPACK and should be very robust and efficient.

Anne



More information about the SciPy-User mailing list