fixed aggregation, added sum as default output

Change-Id: Ie4697e82d0daf476cd9760a986065661d1bfd59e