executing examples with as_factor() errors. I think due to redundancy. Will investigate.

This commit is contained in:
Andreas Gammelgaard Damsbo 2024-11-20 12:40:29 +01:00
commit c86ae9a364
No known key found for this signature in database
13 changed files with 58 additions and 24 deletions

View file

@ -36,6 +36,7 @@ Please refer to parent functions for extended documentation.
}
\examples{
# will preserve all attributes but class
\dontrun{
c(1, 4, 3, "A", 7, 8, 1) |> as_factor()
structure(c(1, 2, 3, 2, 10, 9),
labels = c(Unknown = 9, Refused = 10)
@ -47,5 +48,5 @@ structure(c(1, 2, 3, 2, 10, 9),
class = "haven_labelled"
) |>
as_factor()
}
}