
Convert to a duckplyr data frame
Source:R/as_duckplyr_df.R, R/as_duckplyr_tibble.R
as_duckplyr_df.RdThese functions convert a data-frame-like input to an object of class "duckpylr_df".
For such objects,
dplyr verbs such as dplyr::mutate(), dplyr::select() or dplyr::filter() will attempt to use DuckDB.
If this is not possible, the original dplyr implementation is used.
as_duckplyr_df() requires the input to be a plain data frame or a tibble,
and will fail for any other classes, including subclasses of "data.frame" or "tbl_df".
This behavior is likely to change, do not rely on it.
as_duckplyr_tibble() converts the input to a tibble and then to a duckplyr data frame.
Value
For as_duckplyr_df(), an object of class "duckplyr_df",
inheriting from the classes of the .data argument.
For as_duckplyr_tibble(), an object of class
c("duckplyr_df", class(tibble())) .
Details
Set the DUCKPLYR_FALLBACK_INFO and DUCKPLYR_FORCE environment variables
for more control over the behavior, see config for more details.