From e4ad2c3024c4e114c5f046c7fa0d73e2168f0d2b Mon Sep 17 00:00:00 2001 From: Vitalie Spinu Date: Tue, 3 Oct 2017 22:39:02 +0200 Subject: [PATCH] [Fix #564] Document epiweek as US CDC week --- R/accessors-week.r | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/R/accessors-week.r b/R/accessors-week.r index 54a7174f..8f4062a2 100644 --- a/R/accessors-week.r +++ b/R/accessors-week.r @@ -41,19 +41,18 @@ week <- function(x) 1L + (as.numeric(date) - jan1) %/% 7L } -#' @description -#' `isoweek()` returns -#' the week as it would appear in the ISO 8601 system, which uses a reoccurring -#' leap week. +#' @description `isoweek()` returns the week as it would appear in the ISO 8601 +#' system, which uses a reoccurring leap week. #' @rdname week #' @export isoweek <- function(x) { .other_week(x, 1) } -#' @description -#' `epiweek()` returns the week as it conventional in -#' epidemiology. Epiweek follows same rules as `isoweek()` but starts on Sunday. +#' @description `epiweek()` is the US CDC version of epidemiological week. It +#' follows same rules as `isoweek()` but starts on Sunday. In other parts of +#' the world the convention is to start epidemiological weeks on Monday, +#' which is the same as `isoweek`. #' #' @rdname week #' @export