Skip to content
Prev 267391 / 398503 Next

identifying weeks (dates) that certain days (dates) fall into

Hi:

You could try the lubridate package:

library(lubridate)
week(weekly$week)
week(july4)
[1] 27 27
function (x)
yday(x)%/%7 + 1
<environment: namespace:lubridate>

which is essentially Gabor's code :)

HTH,
Dennis

On Tue, Aug 2, 2011 at 7:36 AM, Dimitri Liakhovitski
<dimitri.liakhovitski at gmail.com> wrote: