added daysHist feature and reduced boilerplating with getMins