Group structured array entries on multiple levels.