BookmarkSubscribe
Choose Language Hide Translation Bar
lwx228
Community Trekker

How to create validation with JSL as a "cut point" is not successful?

Ask everyone again and again, thank you!
As shown in the figure: I created the validation column in the "age" column as a "cut point", but the JSL code was not successfully generated.

 

dt = Open( "$SAMPLE_DATA/Big Class.jmp" );
dt << Make Validation Column( Training Set( 0.75 ), Validation Set( 0.25 ), cutpoint );

 

2018-09-12_22-02-20.png

0 Kudos
13 REPLIES 13
susan_walsh1
Staff (Retired)

Re: How to create validation with JSL as a "cut point" is not successful?

It looks to me like the validation column was created as expected. You should have seen a message that stated the training set begins with Age 12 and the Validataion set begins with Age 15. That gives you a 67.5% and 32.5% split, but it is the closest you can come to 75/25 and still keep the ages together. Can you explain what you wanted to happen?

 

Or perhaps I misunderstand and you were looking to do this with JSL?

0 Kudos
lwx228
Community Trekker

Re: How to create validation with JSL as a "cut point" is not successful?


I'm sorry to give you an example that doesn't happen, but of course you just want to know how to write JSL code that USES "cut points" to create validation columns.


A good example: there are 100 different dates in the first column, followed by several other columns.I now need to create the validation column with the first column "cut", how to code JSL, thank you!

 

 

2018-09-12_23-01-15.png

0 Kudos
lwx228
Community Trekker

Re: How to create validation with JSL as a "cut point" is not successful?

Click the window menu to do this "cutpoint" operation, it will pop up the prompt window, not data error.I did not find the script in the script index.Thank you very much!
0 Kudos
lwx228
Community Trekker

Re: How to create validation with JSL as a "cut point" is not successful?

The search is similar to this code:

dt << Make Validation Column( Training Set( 0.75 ), Validation Set( 0.25 ), Formula Random );

Code without cut points
0 Kudos
Highlighted
lwx228
Community Trekker

Re: How to create validation with JSL as a "cut point" is not successful?

Can't do this with JSL?Thank you very much!
0 Kudos
lwx228
Community Trekker

Re: How to create validation with JSL as a "cut point" is not successful?

Change a way:

dt<<Sort(By(1),Order(ascending),replacetable(1));
New Column("Validation",Numeric,Continuous,Width(8));
dt[ 1::50, "Validation"]=0;dt[ 51::75, "Validation"]=1;dt[ 76::100, "Validation"]=2;
susan_walsh1
Staff (Retired)

Re: How to create validation with JSL as a "cut point" is not successful?

As you have discovered the cutpoint validation is not currently directly scriptable without having to at least click the OK button interactively. Your solution is an excellent workaround for now and we expect to have a more direct approach in JMP 14.2 when it is released.

lwx228
Community Trekker

Re: How to create validation with JSL as a "cut point" is not successful?

Could you tell me whether the function of generating "cut point" validation column directly with JSL has been realized in version 14.2?

 

Thanks!

0 Kudos
lwx228
Community Trekker

Re: How to create validation with JSL as a "cut point" is not successful?

Could you tell me whether the function of generating "cut point" validation column directly with JSL has been realized in version 14.2?

Thanks!

0 Kudos