Modified querier to use grouping to improve efficiency.
Modified calculator and formatter to allow any number of cohorts.