tests/testthat/_snaps/sparse_dummy.md

sparse_dummy() errors with wrong input

Code
  sparse_dummy(letters)
Condition
  Error in `sparse_dummy()`:
  ! `x` must be a factor, not a character vector.
Code
  sparse_dummy(mtcars)
Condition
  Error in `sparse_dummy()`:
  ! `x` must be a factor, not a data frame.
Code
  sparse_dummy(1:5)
Condition
  Error in `sparse_dummy()`:
  ! `x` must be a factor, not an integer vector.
Code
  sparse_dummy(NULL)
Condition
  Error in `sparse_dummy()`:
  ! `x` must be a factor, not NULL.


Try the sparsevctrs package in your browser

Any scripts or data that you put into this service are public.

sparsevctrs documentation built on June 8, 2025, 1:48 p.m.