Skip to content

Commit

Permalink
remove unemployment task from test
Browse files Browse the repository at this point in the history
  • Loading branch information
bblodfon committed Jan 1, 2025
1 parent 8f5651e commit 48dc1f8
Showing 1 changed file with 4 additions and 5 deletions.
9 changes: 4 additions & 5 deletions tests/testthat/test_single_step.R
Original file line number Diff line number Diff line change
@@ -1,19 +1,18 @@
test_that("single-step surv", {
task = mlr_tasks$get("unemployment")
task = mlr_tasks$get("gbcs")
learner = mlr_learners$get("surv.kaplan")

train_task = task$clone()$filter(1:3000)
train_task = task$clone()$filter(1:600)
learner$train(train_task)
newdata = remove_named(task$clone()$filter(3001:3343)$data(), task$target_names)
newdata = remove_named(task$clone()$filter(601:686)$data(), task$target_names)
p = learner$predict_newdata(task = train_task, newdata = newdata)

p = as.data.table(p)
expect_data_table(p, nrow = 343L)
expect_data_table(p, nrow = 86L)
expect_true(allMissing(p$time))
expect_true(allMissing(p$status))
})


test_that("single-step dens", {
task = tsk("faithful")
learner = lrn("dens.kde")
Expand Down

0 comments on commit 48dc1f8

Please sign in to comment.