1

Using a JSL script, I plot several variables V1, V2, V3 (and so on) from two conditions A and B against each other to see how well-correlated they are. For example. V1 of A vs. V1 of B.

I then send the graphs to a JMP report so all graphs will appear in just one window.

In JMP, I use the "Fit Line" command to generate the R square table. Then, I used "Fit Special" command to generate a line where the slope is equal to 1. Hence, I create linear regression lines and create regression reports. See http://www.jmp.com/support/help/Regression_Reports.shtml#846953

My question is this. How do I "extract" the numbers from the regression reports and place them in a variable?

My purpose is this. I need to tabulate the R square values and y-intercept in single table. Right now, I am manually typing.

Thank you very much.

schrodingerscat
  • 189
  • 1
  • 3
  • 15
  • 1
    I don't know if you ever got an answer, but you can click the right button anywhere in the table text and select "Make into data table." – Edward Carney Nov 16 '16 at 19:07
  • Thank you! I never knew of this feature before. Hm, is there a way to execute this command using a JSL script? Thanks again. – schrodingerscat Nov 22 '16 at 04:50

1 Answers1

1

Here's a sample based on the Blood Pressure sample data in JMP:

We'll do a "Fit X to Y" using "BP 6M" for X and "BP 8M" for Y and add a fit line. This initial part was done with "Save Script to Script Window." The naming of biv + the rest was added.

/* get the Bivariate fit with its Fit Line into a variable */
biv = Bivariate( Y( :BP 8M ), X( :BP 6M ), Fit Line( {Line1 Color( {213, 72, 87} )} ) );

/* get the report into a variable */
reportbiv = biv << Report;

/* output the Summary of Fit to a table */
dt = reportbiv["Summary of Fit"][1] << MakeIntoDataTable;
Edward Carney
  • 1,372
  • 9
  • 7
  • 1
    BTW, check this link for the source of this code and more information--http://stackoverflow.com/questions/32978580/pull-out-r-squared-from-fit-model-to-table-in-jsl-jmp – Edward Carney Nov 23 '16 at 12:17