Skip to content

Commit

Permalink
Merge branch 'master' into handle_multi_role_cols
Browse files Browse the repository at this point in the history
  • Loading branch information
mb706 authored Jan 21, 2025
2 parents 690a00f + f8e8bc0 commit 425adef
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 0 deletions.
1 change: 1 addition & 0 deletions NEWS.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
* Dictionary sugar functions `po()` / `pos()` / `ppl()` / `ppls()` now make suggestions for entries in both `mlr_pipeops` as well as `mlr_graphs` when an object by the given name could not be found in the respective dictionary.
* New PipeOp `PipeOpDecode` / `po("decode")` to reverse one-hot or treatment encoding.
* Fix: Columns that are `feature` and something else no longer lose the other column role during training or prediction.
* Fix: Made tests for `PipeOpBLSmote` deterministic.

# mlr3pipelines 0.7.1

Expand Down
2 changes: 2 additions & 0 deletions tests/testthat/test_pipeop_blsmote.R
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ test_that("PipeOpBLSmote - train works as intended", {

op = PipeOpBLSmote$new()

set.seed(1234)
df = smotefamily::sample_generator(500, 0.8)
df$result = factor(df$result)
df = df[, c(3L, 1L, 2L)] # we do this to avoid reordering later
Expand Down Expand Up @@ -75,6 +76,7 @@ test_that("PipeOpBLSmote - handling of feature named 'class'", {

op = PipeOpBLSmote$new()

set.seed(1234)
df = smotefamily::sample_generator(500, 0.8)
df$result = factor(df$result)
# Rename a column into "class"
Expand Down

0 comments on commit 425adef

Please sign in to comment.