groupBy steps