[SciPy-user] curve_fit step-size and optimal parameters
Stéfan van der Walt
stefan at sun.ac.za
Mon Jun 8 16:15:30 EDT 2009
2009/6/8 Robert Kern <robert.kern at gmail.com>:
> On Mon, Jun 8, 2009 at 14:59, ElMickerino<elmickerino at hotmail.com> wrote:
>> My question is, how can I get curve_fit to use a very small step-size for
>> the phase, or put in strict limits, and to therefore get a robust fit. I
>> don't want to tune the phase by hand for each of my 60+ datasets.
>
> You really can't. I recommend the A*sin(w*t)+B*cos(w*t)
> parameterization rather than the A*sin(w*t+phi) one.
Could you expand? I can't immediately see why the second
parametrisation is bad. Can't a person do this fit using non-linear
least-squares? Ah, that's probably why you use the other
parametrisation, so that you don't have to use non-linear least
squares?
Regards
Stéfan
More information about the SciPy-User
mailing list