I have the following code which converts index to week number as well as another column is added with week number: As you can see there are instances where week 11 is being shown in the index column using df.index.strftime(‘%U’) when the week number is showing as 12 using df.index.isocalendar().week Why are there week number different in index column as
Tag: week-number
Getting all starting dates of year 2020 with ISO week frequency
I’d like to create a list of dates each of which represents the starting date of ISO week N of year 2020. Something like: I have obtained something similar using timedelta(weeks=1), and adding this to my START_DATE (date(2020, 1, 1)), but the dates I obtain are not correct. I know I could simply change my START_DATE to be date(2019, 12,