The following warnings occurred:
Warning [2] count(): Parameter must be an array or an object that implements Countable - Line: 795 - File: showthread.php PHP 7.4.33 (FreeBSD)
File Line Function

 Customizing Inference App?
11-16-2014, 12:26 AM
Post: #1
 mbeddo Member Posts: 54 Joined: Nov 2014
Customizing Inference App?
In my physics lab the other night, we were validating the equation for the magnetic force on a current carrying wire: Force = Current*Length*MagneticField. The HP Prime was very useful and the students like it over their TI-84 and nSpire calculators - the touchscreen was a hit, as well as a more rational layout of keys.

We used the Spreadsheet app to collect our raw data and process it. Then we copied the appropriate columns into the Statistics_2Var app so we could calculate statistics for the Force vs Current and Force vs Length graphs. The magnetic field was fixed but we didn't know it's strength. So I set up a regression between Current*Length and Force, knowing the slope would be the magnetic field strength. We got -0.11 Tesla.

I wanted to do inference on the slope (magnetic field), so I started the Inference app, went to the Symbolic view to select the "Regression" method and the "Interval: Slope" type. In the Numeric view the Xlist and Ylist were empty. There didn't seem to be a way for importing from a list from another app. I could do this in the Home view, of course, but I want to get my feet wet learning to program the HP Prime, so I looked for a way to customize the context-sensitive menus at the bottom of the Numeric view. I couldn't find a way to do it in the User Guide.

So I copied the Inference app to "Inference Copy" and then added a VIEW:

EXPORT Inference_Copy()
BEGIN

END;

VIEW "Copy C1, C2 into Xlist, Ylist", COPY_C1C2()
BEGIN
Xlist := Statistics_2Var.C1;
Ylist := Statistics_2Var.C2;
END;

Now I can click on the View button and copy the data in one step. Of course, this could be made more sophisticated (once I learn how) asking me from which app to copy data from, etc.

But I'd really like this operation to be available as a context menu in the Numeric view (where I think it belongs) if the inference method is regression (the other methods have a context menu "Import" which brings in statistics from the other apps).

Is this biting off more than I should chew? Perhaps a better solution is to provide a function for NumSetup?

Attached File(s) Thumbnail(s)

 « Next Oldest | Next Newest »

 Messages In This Thread Customizing Inference App? - mbeddo - 11-16-2014 12:26 AM RE: Customizing Inference App? - Han - 11-16-2014, 01:17 AM RE: Customizing Inference App? - mbeddo - 11-16-2014, 02:08 AM RE: Customizing Inference App? - Han - 11-16-2014, 02:38 AM RE: Customizing Inference App? - Tim Wessman - 11-16-2014, 04:03 AM RE: Customizing Inference App? - mbeddo - 11-18-2014, 08:24 AM RE: Customizing Inference App? - Han - 11-18-2014, 02:03 PM RE: Customizing Inference App? - Tim Wessman - 11-18-2014, 02:37 PM RE: Customizing Inference App? - Han - 11-18-2014, 03:50 PM RE: Customizing Inference App? - Han - 11-18-2014, 02:23 PM RE: Customizing Inference App? - salvomic - 03-14-2015, 09:24 PM RE: Customizing Inference App? - salvomic - 05-14-2015, 09:48 AM

User(s) browsing this thread: 1 Guest(s)