compute for a range of dates