- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Get Direct Link
- Report Inappropriate Content
How to construct a JMP add-in to run a floating window with click boxes for different sequentially dependent scripts?
I have two main scripts (1) trendStudy (2) corrStudy, both of which call a bunch of other scripts but corrStudy does not call any scripts which trendStudy calls.
trendStudy produces a data table and a chart. corrStudy needs to use the data table created by trendStudy. Both set of scripts are working.
I want to have these two scripts built into a JMP add-in in the following way.
- When the add-in is started, a small floating window (always visible) appears with two click button boxes showing [Run trendStudy (Trend Plots)] and below it [Run corrStudy (Correlation Study)].
- Clicking on Run trendStudy button box only runs the trendStudy (and associated scripts) producing a trend chart and data table.
- Clicking on corrStudy button box runs corrStudy (and associated scripts) to produce the correlation study plots.
- corrStudy does not run if trendStudy has not been run and throws a warning "Run trendStudy first!"
- Closing the add-in window closes all open data-tables and chart windows with a warning such as "This will close all open tables and charts"
How to build such a JMP add in (I am especially struggling to understand how to separate the two trendStudy and corrStudy)?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Get Direct Link
- Report Inappropriate Content
Re: How to construct a JMP add-in to run a floating window with click boxes for different sequentially dependent scripts?
Here is an example of the structure to use to run one script or another
Names Default To Here( 1 );
New Window( "Example",
Button Box( "Run trend Study", Print( "Place the trend study script here" ) ),
Button Box( "Run corrStudyStudy", Print( "Place the corrStudy script here" ) )
);
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Get Direct Link
- Report Inappropriate Content
Re: How to construct a JMP add-in to run a floating window with click boxes for different sequentially dependent scripts?
In addition to what @txnelson suggested, you can control the activity of a button with << Enabled(0|1)
Names Default To Here(1);
New Window("Example",
Button Box("Run trend Study", Print("Place the trend study script here")),
Button Box("Run corrStudyStudy", Print("Place the corrStudy script here"), <<Enabled(0))
);
How to close all tables / graphs / windows and how to pass correct tables to corrStudy depends on how you have built your main scripts