Simple convenience wrapper around SciPy’s optimize.leastsq.
The advantage of using this wrapper instead of optimize.leastsq directly is, that it automatically constructs an appropriate error function and easily deals with 2d data arrays, i.e. each column with multiple values for the same function argument (x-value).
Parameters : | fx : functor
params : sequence
y : 1d or 2d array
x : Corresponding function arguments (x-values) for each datapoint, i.e.
**kwargs :
|
---|---|
Returns : | tuple : as returned by scipy.optimize.leastsq
|