Realized basic function, need to apply aggregation.