Just like the in the Chart
Thanks!
dt = Open( "$SAMPLE_DATA/Big Class.jmp" );
dt << New Column( "r", formula( If( Row() == 1 | :age != Lag( :age, 1 ), 1, Lag( :r, 1 ) + 1 ) ) );
dt << run formulas;
Column( "r" ) << deleteFormula;
dt << Graph Builder(
Show Control Panel( 0 ),
Show Legend( 0 ),
Variables( X( :r ), Y( :weight ), Group Y( :age ) ),
Elements( Line( X, Y, Legend( 1 ), Summary Statistic( "Sum" ) ) )
);

Is this the chart you are looking for? If so, just remove Age from the Y grouping and then make Age an Overlay variable and save the script
