Convert Dates to Arbitrary Week Definitions

Which day a week starts depends heavily on the either the local or professional context. This package is designed to be a lightweight solution to easily switching between week-based date definitions.


aweek 0.2.2

  • Simplified conversion to factors.
  • Using factor = TRUE without floor_day = TRUE will now issue a message indicating that this is deprecated in future versions of aweek (see #13).

aweek 0.2.1

  • Fix bug where NAs threw errors in the dates (found: @aspina7, #12)

aweek 0.2.0

  • Subsetting and concatenating methods added to the aweek class (see #1)
  • Documentation divided into smaller chunks
  • as.POSIXlt() bug where tz was not being passed was fixed.
  • date2week(): an error is now issued if users specify non-ISO 8601 dates OR don't specify a format option. (found: @scottyaz, #2)
  • Best practices added to vignette
  • Fix test that would fail every seven days on CRAN

aweek 0.1.0

  • First official release of aweek on CRAN


  • date2week() and week2date() can now take days represented as characters in the current or English locale.


  • date2week() gains a factor argument, which will automatically compute the levels within the date range.


  • date2week() now properly accounts for dates in December that occur in the first week of the next year.


  • floor_day now truncates the week instead changing the last digit to 1 for aesthetics. (Thanks to @aspina7 for the suggestion) q print.aweek() now displays the day of the week in the current locale.


  • First version of package
  • date2week() converts dates to aweek objects
  • week2date() converts aweek objects or character strings to dates
  • as.Date() does the same thing as above
  • as.POSIXlt() as well
  • as.character() unclasses the aweek object
  • Added a file to track changes to the package.

Reference manual

It appears you don't have a PDF plugin for this browser. You can click here to download the reference manual.


1.0.2 by Zhian N. Kamvar, a year ago

Report a bug at

Browse source code at

Authors: Zhian N. Kamvar [aut, cre]

Documentation:   PDF Manual  

MIT + file LICENSE license

Suggests testthat, stats, roxygen2, knitr, rmarkdown, covr, spelling

Imported by ARPALData, incidence.

See at CRAN