- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Get Direct Link
- Report Inappropriate Content
transpose list of lists (summarize()) without a for loop
Can anyone think of a way to transpose a list of lists like what comes from the following script so that each row is grouped together instead of by column.
I know I can do it with a for loop but I'm wondering if there's anything better or less brute.
Names default to here(1);
dt = open("$SAMPLE_DATA\Big Class.jmp");
summarize(dt, d = By(:age, :sex));
rows = nitems(d);
cols = nitems(d[1]);
show(rows, cols);
// rows = 2;
// cols = 12;
For this I want to change it from 2 lists of 12 to 12 lists of 2.
Adding a few people that I think might either like this challenge or already have something.
@pmroz, @Justin_Chilton, @gzmorgan0, @msharp, @ms
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Get Direct Link
- Report Inappropriate Content
Re: transpose list of lists (summarize()) without a for loop
Repeat: MS your repeat solution is very nice. :)
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Get Direct Link
- Report Inappropriate Content
Re: transpose list of lists (summarize()) without a for loop
I had the exact same question @vince_faller . Thanks for asking. I've posted a request for a feature like this to be added to the next version of JMP. Let's see...
https://community.jmp.com/t5/JMP-Wish-List/Transpose-List-of-Lists-without-a-for-loop/idi-p/348968
- « Previous
-
- 1
- 2
- Next »