get_stats function

Get Carbon Intensity statistics between from and to dates