It looks like you're new here. If you want to get involved, click one of these buttons!
import datetimestartdate = datetime.datetime( 2008, 10, 1, 9, 15, 0)while True: enddate = startdate + datetime.timedelta(days=100) # fetch historical data here for 100 days from startdate to enddate. # This next line will set the start date for next iteration to the next date after enddate. startdate = enddate + datetime.timedelta(days=1)
in python you would do something like