tidypolars 0.10.0
tidypolars
requires polars
>= 0.19.1.
Breaking changes and deprecations
-
describe()
is deprecated as of tidypolars 0.10.0 and will be removed in a
future update. Usesummary()
with the same arguments instead (#127). -
describe_plan()
anddescribe_optimized_plan()
are deprecated as of
tidypolars 0.10.0 and will be removed in a future update. Useexplain()
with
optimized = TRUE/FALSE
instead (#128). -
In
sink_parquet()
andsink_csv()
, all arguments except for.data
and
path
must be named (#136).
New features
-
Add support for more functions:
- from package
base
:substr()
.
- from package
-
Better error message when a function can come from several packages but only
one version is translated (#130). -
row_number()
now works without argument (#131). -
New functions to import data as Polars DataFrames and LazyFrames (#136):
read_<format>_polars()
to import data as a Polars DataFrame;scan_<format>_polars()
to import data as a Polars LazyFrame;<format>
can be "csv", "ipc", "json", "parquet".
Those can replace functions from
polars
. For example,
polars::pl$read_parquet(...)
can be replaced by
read_parquet_polars(...)
. -
New functions to write Polars DataFrames to external files:
write_<format>_polars()
where<format>
can be "csv", "ipc", "json",
"ndjson", "parquet" (#136). -
New function
sink_ipc()
that is similar tosink_parquet()
andsink_csv()
but for IPC files (#136). -
across()
now throws a better error message when the user passes an external
list to.fns
. This works withdplyr
but cannot work withtidypolars
(#135). -
Added support for argument
.add
ingroup_by()
.
Bug fixes
-
stringr::str_sub()
now works when bothstart
andend
are negative. -
Fixed a bug in
str_sub()
whenstart
was greater than 1. -
stringr::str_starts()
andstringr::str_ends()
now work with a regex. -
fill()
doesn't error anymore when...
is empty. Instead, it returns the
input data. -
unite()
now provides a proper error message whencol
is missing. -
unite()
doesn't error anymore when...
is empty. Instead, it uses all
variables in the dataset. -
filter()
,mutate()
andsummarize()
now work when using a column from
another data.frame, e.g.my_polars_df |> filter(x %in% some_data_frame$y)
-
replace_na()
no longer converts the column to the datatype of the replacement,
e.g.data |> replace_na("a")
will error if the input data is numeric. -
n_distinct()
now correctly applies thena.rm
argument when several columns
are passed as input (#137).