Load results from report sheet into a tree
X-Function not designed for Auto GetN Dialog.
1. getresults;
2. getresults tr:=tree;
3. getresults tr:=tree iw:=[Book1]Sheet2! escstr:=0;
Please refer to the page for additional option switches when accessing the x-function from script
Output
TreeNode
The result tree See more details in Description table
Input
Worksheet
The specified worksheet to get the result.
int
Whether to translate the escaped operation strings in the returned tree or not.
This function is used to get the result tree.
This examples shows how to get result values from result tree after doing a nonlinear curve fit.
// Import an Origin Sample file string fpath$ = "Samples\Curve Fitting\Gaussian.dat"; string fname$ = SYSTEM.PATH.PROGRAM$ + fpath$; impasc; // Run a Gauss fit of the data and create a Report sheet nlbegin (1,2) gauss; nlfit; nlend 1 1; // An automatically-created string variable, __REPORT$, // holds the name of the last Report sheet created: string strLastReport$ = __REPORT$; // This is the X-Function which gets the Report into a tree getresults tr:=MyResults iw:=%(strLastReport$); // So now we can access those results ty Variable\tValue\tError; separator 3; ty y0\t$(MyResults.Parameters.y0.Value)\t$(MyResults.Parameters.y0.Error); ty xc\t$(MyResults.Parameters.xc.Value)\t$(MyResults.Parameters.xc.Error); ty w\t$(MyResults.Parameters.w.Value)\t$(MyResults.Parameters.w.Error); ty A\t$(MyResults.Parameters.A.Value)\t$(MyResults.Parameters.A.Error); //Dump MyResults tree MyResults.=; //Dump one node under the tree MyResults.Parameters.y0.=;
Keywords:analysis