grouping inference