aggregate and plot