If all of your grouping variables were numeric, it would be faster, because the summarize would be able to make quick work of the counting. But that is very restrictive to the data and/or the user. You could convert the summarize function calls to "Summary" platforms, and create tables which can handle both numeric and character columns. You could do some timing tests to see if that will work.
Names Default To Here( 1 );
dt = Open( "$SAMPLE_DATA\car physical data.jmp" );
dtsumm=dt << Summary(private,
Group( :type),
N( :type ),
Freq( "None" ),
Weight( "None" )
);
show(dtsumm:type<<get values);
close(dtsumm,nosave);
dtsumm=dt << Summary(private,
Group( :country),
N( :country),
Freq( "None" ),
Weight( "None" )
);
show(dtsumm:country<<get values);
close(dtsumm,nosave);
Jim