Skip to content

v0.9.0

Compare
Choose a tag to compare
@github-actions github-actions released this 29 Oct 14:36
· 612 commits to main since this release

BREAKING CHANGES DUE TO RUST-POLARS UPDATE

  • rust-polars is updated to 0.33.2 (#417)
    • In all date-time related methods, the argument use_earliest is replaced by ambiguous.
    • In $sample() and $shuffle(), the argument fixed_seed is removed.
    • In $value_counts(), the arguments multithreaded and sort
      (sometimes called sorted) have been swapped and renamed sort and parallel.
    • $str$count_match() gains a literal argument.
    • $arg_min() doesn't consider NA as the minimum anymore (this was already the behavior of $min()).
    • Using $is_in() with NA on both sides now returns NA and not TRUE anymore.
    • Argument pattern of $str$count_matches() can now use expressions.
    • Needs Rust toolchain nightly-2023-08-26 for to build with full features.
  • Rename R functions to match rust-polars
    • $str$count_match() -> $str$count_matches() (#417)
    • $str$strip() -> $str$strip_chars() (#417)
    • $str$lstrip() -> $str$strip_chars_start() (#417)
    • $str$rstrip() -> $str$strip_chars_end() (#417)
    • $groupby() is renamed $group_by(). (#427)

Breaking changes

  • Remove some deprecated methods.
    • Method $with_column() has been removed (it was deprecated since 0.8.0).
      Use $with_columns() instead (#402).
    • Subnamespace $arr has been removed (it was deprecated since 0.8.1).
      Use $list instead (#402).
  • Setting and getting polars options is now made with pl$options,
    pl$set_options() and pl$reset_options() (#384).

What's changed

  • Bump supported R version to 4.2 or later (#435).
  • pl$concat() now also supports Series, Expr and LazyFrame (#407).
  • New method $unnest() for LazyFrame (#397).
  • New method $sample() for DataFrame (#399).
  • New method $meta$tree_format() to display an Expr as a tree (#401).
  • New argument schema in pl$DataFrame() and pl$LazyFrame() to override the
    automatic type detection (#385).
  • Fix bug when calling R from polars via e.g. $map() where query would not
    complete in one edge case (#409).
  • New method $cat$get_categories() to list unique values of categorical
    variables (#412).
  • New methods $fold() and $reduce() to apply an R function rowwise (#403).
  • New function pl$raw_list and class rpolars_raw_list a list of R Raw's, where missing is
    encoded as NULL to aid conversion to polars binary Series. Support back and forth conversion
    from polars binary literal and Series to R raw (#417).
  • New method $write_csv() for DataFrame (#414).
  • New method $sink_csv() for LazyFrame (#432).
  • New method $dt$time() to extract the time from a datetime variable (#428).
  • Method $profile() gains optimization arguments and plot-related arguments (#429).
  • New method pl$read_parquet() that is a shortcut for pl$scan_parquet()$collect() (#434).
  • Rename $str$str_explode() to $str$explode() (#436).
  • New method $transpose() for DataFrame (#440).
  • New argument eager of LazyFrame$set_optimization_toggle() (#439).
  • {polars} can now be installed with "R source package with Rust library binary",
    by a mechanism copied from the prqlr package.
    Sys.setenv(NOT_CRAN = "true")
    install.packages("polars", repos = "https://rpolars.r-universe.dev")
    The URL and SHA256 hash of the available binaries are recorded in tools/lib-sums.tsv.
    (#435, #448, #450, #451)