I was looking for a way to get the week number of the year, from Sunday to Saturday. I googled it… and I had to visit 5 – 6 sites to get what I was looking for. This is way above my expected patience for that kind of question.
The answer is:
1 |
format(as.POSIXct('2014-12-24'),'%U') |
I hope this post will be ranked #1 in Google and you didn’t have to open as many pages like I did.