df = df.rename(columns= {'Close Price': 'Price'}) df = df[800:] df = df[df.index < datetime(2018, 3, 20)]