code: public static Statistics statisticsOf(List<Statistics> data) {
          if (data.isEmpty())
              return null;
          
          Iterator<Statistics> iterator = data.iterator();
          if (!iterator.hasNext()) {
              return null;
          }
          Statistics first = null;
          while (first == null && iterator.hasNext()) {
              first = iterator.next();
          }
          if (first == null)
              return null;
          
          int count = first.getCount();
          double min = first.getMinimum().doubleValue();
          double max = first.getMaximum().doubleValue();
          double total = first.getAverage() * first.getCount();
          double totalSquare = (first.getStdDev() * first.getStdDev() + first.getAverage() * first.getAverage()) * first.getCount();
          
          while (iterator.hasNext()) {
              Statistics stats = iterator.next();
              if (stats.getMaximum().doubleValue() > max)
                  max = stats.getMaximum().doubleValue();
              if (stats.getMinimum().doubleValue() < min)
                  min = stats.getMinimum().doubleValue();
              total += stats.getAverage() * stats.getCount();
              totalSquare += ( stats.getStdDev() * stats.getStdDev() + stats.getAverage() * stats.getAverage() ) * stats.getCount();
              count += stats.getCount();
          }
          
          double average = total/count;
          double stdDev = Math.sqrt(totalSquare / count - average * average);
          
          return new StatisticsImpl(count, min, max, average, stdDev);
      }
docs: Aggregates statistical information.
  
  @param data a list of statistical information
  @return the aggregate of all