Subscribe Bookmark RSS Feed

decimal places in summary table

rahulsmils

Community Trekker

Joined:

Sep 23, 2016

Hi, 

 

I am summarizing a jmp data table. In the summary table, I want the columns to have decimal places till 4.

However, jmp truncates everything after the decimal point.

code2.JPG

When I try to retrieve the format for a column using jsl, it says the format is empty.

dt:Name("Median(A)")<< get property("Format");//Empty
dt:Name("Median(A)")<<Set property("Format", {"Scientific",12,2});//Scriptable[] but no change

 

Applying format through code doesn't work.

However, if I do this manually through column info dialogue box, by specifying decimal points, it does work.

 

I have like 50 columns and I wish to code this decimal format after selecting them.

Any help will be greatly appreciated.

 

 

 

 

 

1 ACCEPTED SOLUTION

Accepted Solutions
txnelson

Super User

Joined:

Jun 22, 2012

Solution

Get Property and Set Property are not the functions to use for the setting and retireving formats.  The "Format" and "Get Format" messages are used.

Names Default To Here( 1 );
dt = Open( "$SAMPLE_DATA\big class.jmp" );
Show( dt:weight << get format );
dt:weight << Format( "Fixed Dec", 12, 6 );
Show( dt:weight << get format );
Jim
2 REPLIES
txnelson

Super User

Joined:

Jun 22, 2012

Solution

Get Property and Set Property are not the functions to use for the setting and retireving formats.  The "Format" and "Get Format" messages are used.

Names Default To Here( 1 );
dt = Open( "$SAMPLE_DATA\big class.jmp" );
Show( dt:weight << get format );
dt:weight << Format( "Fixed Dec", 12, 6 );
Show( dt:weight << get format );
Jim
rahulsmils

Community Trekker

Joined:

Sep 23, 2016

Perfect, works! Thanks.