Auto-suggest helps you quickly narrow down your search results by suggesting possible matches as you type.

- JMP User Community
- :
- Discussions
- :
- How to make a calculus in JMP

- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page

Highlighted
##

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Get Direct Link
- Email to a Friend
- Report Inappropriate Content

How to make a calculus in JMP

Jan 5, 2019 2:06 AM
(4983 views)

How to make a calculus in JMP?

There is a two dimension of data, for instance, current and time, then in JMP Grapher, we can plot a curve and fit it smooth, for detail, please see photo below.

How much electric quantity will be? that means I'd like to know how to calculate the area under the curve?

in mathmatic , how to make a calculus in JMP?

2 REPLIES 2

Highlighted
##

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Get Direct Link
- Email to a Friend
- Report Inappropriate Content

Re: How to make a calculus in JMP

See **Help** > **Scripting Index** and search for **Integrate** function. This function performs numerical integration of your expression (fitted model). Use the Help button in the index to get more information about this function.

Likely you will need to save the fitted model as a new column formula and then use a short script to extract the expression from the formula and use it as an argument to the Integrate() function.

Learn it once, use it forever!

Highlighted
##

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Get Direct Link
- Email to a Friend
- Report Inappropriate Content

Re: How to make a calculus in JMP

Here is a simple example of @markbailey's suggestion.

```
Names default to Here(1);
dt = New Table("Example",
Add Rows( 5 ),
New Column( "Time",
Numeric,
"Continuous",
Format( "Best", 12 ),
Set Values( [0, 2, 4, 6, 8] )
),
New Column( "I",
Numeric,
"Continuous",
Format( "Best", 12 ),
Set Values(
[0.303858872597443, 0.22418155030798, 0.202170635461688,
0.181779722721203, 0.148724968294765]
)
)
);
//use bivariate for simplicity
biv = dt << Bivariate(
Y( :I ),
X( :Time ),
Fit Polynomial( 3, {Confid Shaded Indiv( 1 ), Line Color( {212, 73, 88} )} ),
SendToReport(
Dispatch(
{},
"2",
ScaleBox,
{Min( 0 ), Max( 0.45 ), Inc( 0.05 ), Minor Ticks( 1 )}
)
)
);
//get the prediction formula string
fm = report(biv)[OutlineBox("Polynomial ?")][TextEditBox(1)] << get text;
//get the string to the right of the equal sign and convert the string to an expression using Parse()
fm = Parse(Trim(word(2, fm, "=")));
area = Integrate(fm, Time, col minimum(:Time), col maximum(:Time));
Caption("The area under this curve is " || char(area));
```

Article Labels

There are no labels assigned to this post.