I want to create a list of dates, starting with today, and going back an arbitrary number of days, say, in my example 100 days. Is there a better way to do it than this?
If there are two dates and you need the range try
from dateutil import rrule, parser date1 = '1995-01-01' date2 = '1995-02-28' datesx = list(rrule.rrule(rrule.DAILY, dtstart=parser.parse(date1), until=parser.parse(date2)))