Join GitHub today
GitHub is home to over 50 million developers working together to host and review code, manage projects, and build software together.
Sign upIsoweek() problem in European timezones #311
Comments
Yep. It's a bug. Thanks.
Indeed. The docs should be refactored and isoweek should be at least mentioned in the week docs. |
|
The problem was the small difference introduced by daylight saving time. To avoid this issue the isoweek is computed now exclusively in UTC. It turns out that the documentation for |
Hi, it appears that there is a problem with the
isoweek()function for European timezones.For instance tomorrow, April 14th 2015, it is Tuesday of week 16 here in Copenhagen, Denmark, but
isoweeksays it is week 15:For UTC, it correctly returns week 16:
Note that CEST (Central European Summer Time) is UTC + 2, so this should not influence the week number on a Tuesday afternoon.
It does not work for CET either:
So this appears to be a bug in lubridate or in the general handling of timezones.
(I am using lubridate 1.3.3 with 32-bit R 3.1.3 in RStudio 0.98.1103 on 64-bit Windows 7 SP1.)
Best regards,
Johan
ps: Finding the
isoweek()function in the first place took me actually quite a while, since I did not see it mentioned when I skimmed theweek()documentation via?week. I suggest adding a "See also" section or an example mentioningisoweek()to theweek()documentation to highlight its existence.