This example does the work one-at-a-time because it looks like you might have some specific requirements about what data you want to keep.
dt = Open( "$sample_data/big class.jmp" );
picDt = New Table( "dist pics", New Column( "pics", Expression, "None", Set Values( {} ),Set Display Width( 250 ) ) );
ages = {14, 16, 17};
For( j = 1, j <= N Items( ages ), j++,
dt << Select Where( dt:age == ages[j] );
subsetDt = dt << subset( output table name( Char( ages[j] ) ) );
dist = subsetDt << Distribution(
Continuous Distribution( Column( subsetDt:weight ), Quantiles( 0 ), Summary Statistics( 0 ), Outlier Box Plot( 0 ) )
);
pic = (Report( dist )[Outline Box( "weight" )]) << getpicture;
dist << closewindow();
Close( subsetDt, "nosave" );
picDt << addrows( 1 );
picDt:pics[j] = pic;
);
picDt<<Set Cell Height( 100 );
Three distribution pictures in a table
Use JSL variables to keep track of the tables: dt, subsetDt, picDt. JSL often needs you to be specific about the table when there is more than one being used.
Craige