Feature request: option to set week starting on Sunday instead of Monday
See original GitHub issueProblem description
Currently, calling pd.Series.dt.weekday
returns Monday = 0, Sunday = 6. It would be nice to have a settable option that allows Sunday to be the beginning of the week, e.g.
my_series.dt.weekday # Monday = 0, Sunday = 6
pd.options.week_start = 'Sunday'
my_series.dt.weekday # Sunday = 0, Saturday = 6
Pandas version 1.0.1.
Issue Analytics
- State:
- Created 4 years ago
- Comments:8 (4 by maintainers)
Top Results From Across the Web
How to change the first day of the week in my calendar
Step 3. Under the "First Day Of The Week" select your first day of the week to be Monday or Sunday according to...
Read more >Change Week Start Date - Lose It! Support
There's no way to adjust the weekly start day within Lose It!. For example, you cannot edit the program to start your week...
Read more >Ability to define the start of the week like Outlook Calendar
I define my start of week as Monday instead of Sunday, ... Feature Request: Ability to define the start of the week like...
Read more >Weeks start on Sunday, not Monday - Visual Studio Feedback
I agree that this is set up incorrectly . Monday should be the default value of the week start for non-US countries. The...
Read more >Change first day of week to MONDAY, instead of SUNDAY
Hello! I found that in 2015 there was a request to give users option when the week should begin. In some countries it...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
It is an easy workaround - but pandas is all about convenience, right? 😉
Here’s what I’m currently doing:
You’re correct in that
date.weekday()
returns the same output as pandas currently does - however,datetime
also allows forstrftime()
to be called with%w
for Sunday-first (or compare%W
and%U
). Is this the recommended route when dealing with pandas datetimes, too? It seems silly to convert to string then back for a library meant for efficiency, but I’ll accept it as long as it works…