use treeAggregate instead of aggregate
remove minCount and window from constructor
change model to use float instead of double