Make graph take group size into account