cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
  • Learn how to build custom Python data connectors and further customize JMP’s Data Connector Framework with the Python Data Connector Demo, available now in the JMP Marketplace!
  • See how to create experiments to support product design and ID useful product features. Register for June 12 webinar, 2pm US Eastern Time.

Discussions

Solve problems, and share tips and tricks with other JMP users.
Choose Language Hide Translation Bar
yanee
Level III

Save residual by using jmp script

Hi,

 

I created a script to run a correlation.  there are 2 fit line : a) linear correlation fit , b) 1:1 fit.

I need to save the residual from the 1:1 fit (fit special). how do I do that with the JMP script ?

 

 

plot = data table("Correlation_Raw")<< Bivariate(
Y( :NewTester ),
X( :RefTester ),
Fit Line( {Confid Curves Fit( 1 ), Line Color( {212, 73, 88} )} ),
Fit Special( Intercept( 0 ), Slope( 1 ), {Line Color( {61, 174, 70} )}),
By( :Label )
);
bivRep = plot << Report;

 

 

Thanks.

Yanee

1 ACCEPTED SOLUTION

Accepted Solutions
txnelson
Super User

Re: Save residual by using jmp script

Here is a simple modification of your script that will save residuals for both of your fits.

plot = data table("Correlation_Raw")<< Bivariate(
Y( :NewTester ),
X( :RefTester ),
Fit Line( {Confid Curves Fit( 1 ), Line Color( {212, 73, 88} )} ),
Fit Special( Intercept( 0 ), Slope( 1 ), {Line Color( {61, 174, 70} )}),
By( :Label )
);
bivRep = plot << Report;
plot << (Curve[1] << Save Residuals);
plot << (Curve[2] << Save Residuals);

See the Scripting Index for other examples

     Help==>Scripting Index==>Bivariate==>Save Residuals

Jim

View solution in original post

2 REPLIES 2
txnelson
Super User

Re: Save residual by using jmp script

Here is a simple modification of your script that will save residuals for both of your fits.

plot = data table("Correlation_Raw")<< Bivariate(
Y( :NewTester ),
X( :RefTester ),
Fit Line( {Confid Curves Fit( 1 ), Line Color( {212, 73, 88} )} ),
Fit Special( Intercept( 0 ), Slope( 1 ), {Line Color( {61, 174, 70} )}),
By( :Label )
);
bivRep = plot << Report;
plot << (Curve[1] << Save Residuals);
plot << (Curve[2] << Save Residuals);

See the Scripting Index for other examples

     Help==>Scripting Index==>Bivariate==>Save Residuals

Jim
yanee
Level III

Re: Save residual by using jmp script

thanks ...

Recommended Articles