[SciPy-User] scipy.odr question

Mogliii mogliii@gmx....
Wed Jul 4 15:06:10 CDT 2012


> [clip]
>> mydata = odr.RealData(x, y, sx = x, sy = y)
> What you are effectively saying here is that your data has 100%
> uncertainty both in x and y coordinates. This is a very different
> assumption that what goes into a least-squares fit (no error in
> x-coordinate), so it's no wonder the results differ.
>
> The ODR fit is most likely the correct solution to the problem you are
> posing, but the problem you tell it to solve is not probably what you
> have in mind.
I have no error data, so assuming there is no uncertainty:
1) If I omit sx and sy I get the same result.
2) If I use sx = np.zeros_like(x) I get "RuntimeWarning: divide by zero
encountered in divide"
3) If I use sx = np.ones_like(x) I get the same result

Could you please hint me how to modify the code to honor the fact that
there is no error data?

Very much appreciated
Mogliii

PS: I forgot to introduce myself to the mailing list before. Hi everyone!



More information about the SciPy-User mailing list