From 6e23367e089c82726b89791a205ffc28a5bd9749 Mon Sep 17 00:00:00 2001 From: Emil Hvitfeldt Date: Wed, 13 Nov 2024 10:15:52 -0800 Subject: [PATCH] document the class of columns produced by step_dummy() --- R/dummy.R | 3 ++- man/step_dummy.Rd | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/R/dummy.R b/R/dummy.R index 9ead0d559..19e85ea8b 100644 --- a/R/dummy.R +++ b/R/dummy.R @@ -63,7 +63,8 @@ #' this step. #' #' Also, there are a number of contrast methods that return fractional values. -#' The columns returned by this step are doubles (not integers). +#' The columns returned by this step are doubles (not integers) when +#' `sparse = FALSE`. The columns returned when `sparse = TRUE` are integers. #' #' The [package vignette for dummy variables](https://recipes.tidymodels.org/articles/Dummies.html) #' and interactions has more information. diff --git a/man/step_dummy.Rd b/man/step_dummy.Rd index 3b8425040..1a6b91560 100644 --- a/man/step_dummy.Rd +++ b/man/step_dummy.Rd @@ -112,7 +112,8 @@ be changed by passing in a different function to the \code{naming} argument for this step. Also, there are a number of contrast methods that return fractional values. -The columns returned by this step are doubles (not integers). +The columns returned by this step are doubles (not integers) when +\code{sparse = FALSE}. The columns returned when \code{sparse = TRUE} are integers. The \href{https://recipes.tidymodels.org/articles/Dummies.html}{package vignette for dummy variables} and interactions has more information.