class BatchWindowAvg extends BatchWindowAggregate {

    public Datum aggregate(List<Datum> data) {
        if (data.isEmpty())
            return new Datum(new ArrayList<>(), new ArrayRealVector(dim));

        dim = data.get(0).metrics().getDimension();
        double[] results = new double[dim];
        for (Datum d : data) {
            RealVector metrics = d.metrics();
            for (int i = 0; i < dim; i ++) {
                if (timeColumn != null && i == timeColumn)
                    continue;
                results[i] += metrics.getEntry(i) / data.size();
            }
        }

        return new Datum(new ArrayList<>(), new ArrayRealVector(results));
    }

    public  BatchWindowAvg();
    public  BatchWindowAvg(MacroBaseConf conf);

}