HP Forums

Full Version: Stat 2var user-custom function not working?
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Hello all

Is it me or the Stat 2var app won't fit data to user-defined functions? I tested all the other options and they seem to be working fine.

Thanks
(02-24-2015 06:23 PM)Offroad Wrote: [ -> ]Hello all

Is it me or the Stat 2var app won't fit data to user-defined functions? I tested all the other options and they seem to be working fine.

Thanks

If your function is defined in F1(X), you will need to "edit" the formula by manually typing in "F1(X)" -- even though it's already there -- and it should then plot your function normally.
All the built-in options will result in an actual regression. The "user-defined" option is not an actual fitting (regression) option. Is is merely an option that allows you to type in your own user function that may then be plotted alongside the scatter plot. The default user-function is F1(X) (from the Function app).
(02-24-2015 07:36 PM)Han Wrote: [ -> ]All the built-in options will result in an actual regression. The "user-defined" option is not an actual fitting (regression) option. Is is merely an option that allows you to type in your own user function that may then be plotted alongside the scatter plot. The default user-function is F1(X) (from the Function app).
I see. And it seems to me that defining the function as "F1(X)" did not help. If you Eval it, the Prime will just call your user-defined function.

Should we call it a bug or an unfinished feature?
(02-24-2015 07:45 PM)Offroad Wrote: [ -> ]
(02-24-2015 07:36 PM)Han Wrote: [ -> ]All the built-in options will result in an actual regression. The "user-defined" option is not an actual fitting (regression) option. Is is merely an option that allows you to type in your own user function that may then be plotted alongside the scatter plot. The default user-function is F1(X) (from the Function app).
I see. And it seems to me that defining the function as "F1(X)" did not help. If you Eval it, the Prime will just call your user-defined function.

Should we call it a bug or an unfinished feature?

Well, there is a bug (as I mentioned previously). I'm not sure about unfinished features, though. I vaguely recall a thread in the past that explained the user-defined function as basically a means to allow users to propose their own formula in an attempt to match the scatter plot and that it was not the case that the app would try to fit the data to said function.

That said, it would not be difficult to do. The idea is to basically feed the user's data into the user-defined formula and produce a (possibly extremely large) system of equations that can be solved using least-squares. In fact, my suspicion is that they probably already have the code (as suggested by the fact that the app does regressions that typically require iterative methods). Why it's not already a feature... I have no answer :-)
(02-24-2015 09:57 PM)Han Wrote: [ -> ]
(02-24-2015 07:45 PM)Offroad Wrote: [ -> ]I see. And it seems to me that defining the function as "F1(X)" did not help. If you Eval it, the Prime will just call your user-defined function.

Should we call it a bug or an unfinished feature?

Well, there is a bug (as I mentioned previously). I'm not sure about unfinished features, though. I vaguely recall a thread in the past that explained the user-defined function as basically a means to allow users to propose their own formula in an attempt to match the scatter plot and that it was not the case that the app would try to fit the data to said function.

That said, it would not be difficult to do. The idea is to basically feed the user's data into the user-defined formula and produce a (possibly extremely large) system of equations that can be solved using least-squares. In fact, my suspicion is that they probably already have the code (as suggested by the fact that the app does regressions that typically require iterative methods). Why it's not already a feature... I have no answer :-)

Well, honestly, it seems more like a bug than an unfinished feature to me. The idea of contrasting user-defined function against data is interesting, provided you have the parameters already.

Edit: Just checked the manual, it's not a bug, maybe a feature that is yet to be implemented.
Reference URL's