Page 1 of 1

In [9]: df Out [9]: 0 7.263616 Chocolate 1 9.295601 Icecream 2 6.871386 Icecream 3 6.059927 Chocolate 4 5.574106 Chocola

Posted: Sun May 15, 2022 12:12 pm
by answerhappygod
In 9 Df Out 9 0 7 263616 Chocolate 1 9 295601 Icecream 2 6 871386 Icecream 3 6 059927 Chocolate 4 5 574106 Chocola 1
In 9 Df Out 9 0 7 263616 Chocolate 1 9 295601 Icecream 2 6 871386 Icecream 3 6 059927 Chocolate 4 5 574106 Chocola 1 (90.72 KiB) Viewed 51 times
In [9]: df Out [9]: 0 7.263616 Chocolate 1 9.295601 Icecream 2 6.871386 Icecream 3 6.059927 Chocolate 4 5.574106 Chocolate oft TO 995 6.355084 Icecream 996 6.919248 Chocolate 997 8.750277 Icecream 998 9.305044 Icecream 999 3.464517 Chocolate 1000 rows x 2 columns tid Reset the index to the past days. If there are n rows in the dataframe, then create a series of n past days and replace the index with these days