I'm trying to recreate JMP's internal behavior: When doing a combined table in a distribution report, the resulting table will list the by value in the first column. When I create my own nested table structure I do not get this first column in the resulting combined data table. How can I define my window structure in such a way that I will generate two identical combined data tables?
See the difference by running this example script:
/* Open a sample data table */
dt = Open( "$SAMPLE_DATA\Big Class.jmp" );
/* Generate the Distribution with a By variable */
dist = dt << Distribution( Continuous Distribution( Column( :height ) ), By( :sex ) );
/* Create the combined data table of Summary Statistics */
Report( dist[1] )["Summary Statistics"][Table Box( 1 )] << Make Combined Data Table;
TestWindow = new window("Test with multiple tables",main = v list box());
main << Append(
Outline Box( "Distributions sex=F",
Outline Box( "height",
Outline Box( "Summary Statistics",
Table Box(
String Col Box("",
{"Mean", "Std Dev", "Std Err Mean", "Upper 95% Mean", "Lower 95% Mean", "N", "Sum", "Variance", "CV", "N Missing"}
),
Number Col Box("",
{60.8888888888889, 3.61189031311679, 0.851330711102296, 62.6850396850604, 59.0927380927173, 18, 1096, 13.0457516339869,
5.93193664562977, 0}
)
)
)
)
)
);
main << Append(
Outline Box( "Distributions sex=M",
Outline Box( "height",
Outline Box( "Summary Statistics",
Table Box(
String Col Box("",
{"Mean", "Std Dev", "Std Err Mean", "Upper 95% Mean", "Lower 95% Mean", "N", "Sum", "Variance", "CV", "N Missing"}
),
Number Col Box("",
{63.9090909090909, 4.3084533840777, 0.918565347870119, 65.8193521238087,
61.9988296943731, 22, 1406, 18.5627705627705, 6.7415344558826, 0}
)
)
)
)
)
);
TestWindow["Summary Statistics"][Table Box( 1 )] << Make Combined Data Table;