I'm pretty new to JSL and I'm stuck on something that seems like it should work, but it isn't. This is what I'm trying to create:
Here's what the dataset looks like (well, it's fake, but you get the point):
and this is the code I'm trying to use:
top15<<Tabulate(
Add Table(
Column Table( Analysis Columns( :Acc_std ) ),
for(i=1,
i<=nitems(top15<<get column names())-1,
i++,
Row Table( Grouping Columns( column name(i) ) )
)
)
);
I'm doing it this way because when I created the tabulate manually the script output was:
Tabulate(
Add Table(
Column Table( Analysis Columns( :Acc_std ) ),
Row Table( Grouping Columns( :A ) ),
Row Table( Grouping Columns( :B ) ),
Row Table( Grouping Columns( :C ) ),
Row Table( Grouping Columns( ) ),
Row Table( Grouping Columns( :E ) )
)
);
instead of writing out each column, I was hoping to just be able to iterate through the columns (using the for loop). Where am I going wrong, or am I completely going down the wrong path here?
Thanks in advance.