Skip to content

Commit 3e4c98e

Browse files
authored
Merge pull request #508 from cmu-delphi/ndefries/remove-name-col-doc
Mark `new_col_name` and `names_sep` as not used for optimized slide fns
2 parents 3430f0e + 0b45656 commit 3e4c98e

File tree

5 files changed

+16
-31
lines changed

5 files changed

+16
-31
lines changed

R/slide.R

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -408,13 +408,19 @@ epi_slide_opt <- function(x, col_names, f, ..., before = NULL, after = NULL, ref
408408
}
409409
if (!is.null(new_col_name)) {
410410
cli_abort(
411-
"`new_col_name` is not supported for `epi_slide_[opt/mean/sum]`",
411+
c(
412+
"`new_col_name` is not supported for `epi_slide_[opt/mean/sum]`",
413+
"i" = "If you want to customize the output column names, use [`dplyr::rename`] after the slide."
414+
),
412415
class = "epiprocess__epi_slide_opt__new_name_not_supported"
413416
)
414417
}
415418
if (!is.null(names_sep)) {
416419
cli_abort(
417-
"`names_sep` is not supported for `epi_slide_[opt/mean/sum]`",
420+
c(
421+
"`names_sep` is not supported for `epi_slide_[opt/mean/sum]`",
422+
"i" = "If you want to customize the output column names, use [`dplyr::rename`] after the slide."
423+
),
418424
class = "epiprocess__epi_slide_opt__name_sep_not_supported"
419425
)
420426
}

man-roxygen/opt-slide-params.R

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,5 @@
99
#' to provide output column names; if you want to customize the output column
1010
#' names, use [`dplyr::rename`] after the slide.
1111
#' @param as_list_col Not supported. Included to match `epi_slide` interface.
12-
#' @param new_col_name Character vector indicating the name(s) of the new
13-
#' column(s) that will contain the derivative values. Default
14-
#' is "slide_value"; note that setting `new_col_name` equal to any existing
15-
#' column names will overwrite those columns. If `names_sep` is `NULL`,
16-
#' `new_col_name` must be the same length as `col_names`.
12+
#' @param new_col_name Not supported. Included to match `epi_slide` interface.
13+
#' @param names_sep Not supported. Included to match `epi_slide` interface.

man/epi_slide_mean.Rd

Lines changed: 2 additions & 8 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

man/epi_slide_opt.Rd

Lines changed: 2 additions & 8 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

man/epi_slide_sum.Rd

Lines changed: 2 additions & 8 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)