Return platform results in a structured way (e.g., as an Associative Array)Advanced users obtain results of platforms (e.g., Fit Model) by scripts. But for this, JMP forces the user to "scrape" the report, which is painful. It will be very helpful if the analysis results are, like in R, returned in a structured way, e.g., as an Associative Array.
Automation and ScriptingContent OrganizationData AccessMass CustomizationSharing and Communicating ResultsRe: Return platform results in a structured way (e.g., as an Associative Array)Thanks, Xan. I know how to scrape JMP reports, and I regularly do this. The problem arises due to inconsistency across different platforms regarding the structure of their reports (as to how they need to be scraped), and with reports that has existed in early days of JMP. For example, the Bivariate command triggers one of the several platforms including Contingency. The Contingency report may have different elements depending on the data, e.g., how many unique values the variables have. This makes the reports nicely simple in human's eyes, but creates headache when these are to be scraped. I hope I can see a consistent "hidden" structure regardless of data, which seems to be found in relatively new reports, in all the JMP reports such as Contingency.
Re: Return platform results in a structured way (e.g., as an Associative Array)Two ways to scrape a report now:
- Get XML() and XPath Query()
biv = Bivariate( Y( :weight ), X( :height ), Fit Line( ) );
x = biv << Get XML();
XPath Query(x, "//NumberColBoxItem[preceding-sibling::NumberColBoxHeader='Estimate']/text()");
// {"-127.1452", "3.7113549"}
nb = report(biv)[OutlineBox("Parameter Estimates")][NumberColBox(1)];
nb << Get As Matrix();
// [-127.145248610913, 3.71135489385953]
Neither is trivial, but an associative array or a giant nested list introduce complexities, too. For instance, an associative array requires unique keys and has no sense of order.