Turn on suggestions

Auto-suggest helps you quickly narrow down your search results by suggesting possible matches as you type.

Showing results for

- JMP User Community
- :
- Discussions
- :
- Discussions
- :
- Exporting table properties to a datatable

Topic Options

- Start Article
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Get Direct Link
- Email to a Friend
- Report Inappropriate Content

Exporting table properties to a datatable

May 17, 2016 8:07 AM
(1605 views)

I have a data table with rows of different parts and each column are various tests for each part. The spec limits for each column are embedded spec limits in each column property. I would like to create a data table where each row is now the parameter, with a column of USL, LSL and mean of each parameter.

Not sure how to do this, any help would be appreciated.

2 REPLIES 2

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Get Direct Link
- Email to a Friend
- Report Inappropriate Content

Re: Exporting table properties to a datatable

Here's one way with JSL.

dt = open("$SAMPLE_DATA\Big Class.jmp");

Column(dt, "height")<< Set Property("Spec LImits", {LSL( 61 ), USL( 65 ), Target( 63 ), Show Limits( 0 )});

Column(dt, "height")<< Set Property("Spec LImits", {LSL( 70 ), USL( 120 ), Target( 90 ), Show Limits( 0 )});

col_names = dt << Get Column Names;

dt_new = New Table("Spec Limits", New Column("Test", Character), New Column("LSL")

, New Column("Target"), New Column("USL")

);

for(i=1, i<=nitems(col_names), i++,

sls = column(dt, col_names*)<<*Get Property("Spec Limits");

if(!isempty(sls),

dt_new << Add Rows({:Test = char(col_names*), :LSL = sls[*"LSL"],

:Target = sls["Target"], :USL = sls["USL"]

}

)

)

);

If you're getting the spec limits from capability analysis you can also get it from the hot button

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Get Direct Link
- Email to a Friend
- Report Inappropriate Content

Re: Exporting table properties to a datatable

I had some old code pretty much the same as that from vince.faller0 above. So I added a couple of lines to also give the mean.