Changed group associations to sortedmap