Subscribe Bookmark RSS Feed

Save "Predicteds" with a specific column name

gutloja

Community Trekker

Joined:

Jul 31, 2015

Hello, All.

Quick question.

Is there a way to save predicteds with a specific column name?

When I use something like this to save predicteds:

Bivariate << (curve[1] << save predicteds);

It saves as "Predicted Name of predicted variable".

Thank you for your time & help,

-JoseL

1 ACCEPTED SOLUTION

Accepted Solutions
Solution

Because JMP will save the predicted as a new column at the far right of your data table, you can use the following code to change the name to whatever name you want to give it:

Assuming you have referenced your data table using a variable called "dt" (i.e. dt=current data table();)

column(N Cols(dt)) << set name("Your new name");

Jim
5 REPLIES
Solution

Because JMP will save the predicted as a new column at the far right of your data table, you can use the following code to change the name to whatever name you want to give it:

Assuming you have referenced your data table using a variable called "dt" (i.e. dt=current data table();)

column(N Cols(dt)) << set name("Your new name");

Jim
gutloja

Community Trekker

Joined:

Jul 31, 2015

Thanks a lot Jim, this worked like a charm.

-JL

mredford

Occasional Contributor

Joined:

Jan 23, 2017

Hi, I'm trying to do this as well. Did you save the predicteds column manually, or was this scripted? I'm hoping to automate the process and script the saving of the column, so if you scripted this, could you share the syntax you used? Thanks!

txnelson

Super User

Joined:

Jun 22, 2012

Here is a sample script that you should be able to use

Names Default To Here( 1 );
dt = Open( "$SAMPLE_DATA\semiconductor capability.jmp" );
biv = Bivariate( Y( :NPN1 ), X( :PNP1 ), Fit Line( {Line Color( {213, 72, 87} )}, save predicteds ) );
biv << (curve[1] << save predicteds);
Column( N Cols( dt ) ) << set name( "Your new name" );
Jim
mredford

Occasional Contributor

Joined:

Jan 23, 2017

Perfect! Thank you so much, I have been struggling all morning to automate this for the spline fit. Thank you for your quick response as well!!