07-19-2023 04:23 AM - edited 07-19-2023 04:43 AM
I am using general polynomial fit function to fit scattered data. But it gives very poor result. However Origin gives good fitting results with the same data and same order(6).
Why?
Attached are the snapshots and VI. Thanks.
WT
LabVIEW2013(32it) and Win10(64bit)
07-19-2023 05:05 AM - edited 07-19-2023 05:06 AM
07-19-2023 08:06 AM
Thanks. This is what I get at another computer(LV2013 and LV2019). I ever got the same result as you sometimes with the same data set. Very strange!
07-19-2023 08:34 AM
I used MathScript polyfit function (green line). You can see the difference.
07-19-2023 10:19 AM
It looks like you're accidentally changing your hidden "method" control to "Bisquare". If I change to Bisquare I get this:
With "Least Square" and "Least Absolute Residual", I get the expected fit:
07-19-2023 07:50 PM
Thanks.
It's weird!
I set the Least Square method and also tried the other two methods.
With the method of Least Absolute Residual, if you run several times, you will get three kind of results.
Something goes wrong with my computer?
07-19-2023 08:00 PM
Solved.
Except the algorithm of SVD* (default), all other algorithms work well.
Thanks.