Changes to support groups of 3 or more duplicate samples