tidymodels / censored

Parsnip wrappers for survival models
https://censored.tidymodels.org/
Other
123 stars 12 forks source link

set mode in set_dependency() #269

Closed EmilHvitfeldt closed 10 months ago

EmilHvitfeldt commented 1 year ago

bug fix for https://github.com/tidymodels/tidymodels.org/pull/45.

This caused the partykit classification model to think it needed censored

library(parsnip)
library(bonsai)
library(censored)

parsnip::get_model_env()$decision_tree_pkgs |>
  dplyr::filter(engine == "partykit", mode == "classification") |>
  dplyr::pull(pkg)
#> [[1]]
#> [1] "partykit" "bonsai"   "censored"
EmilHvitfeldt commented 1 year ago

This PR should be expanded to the entire package not just this case

hfrick commented 10 months ago

I checked the other engines, they were already declaring their mode 👍

github-actions[bot] commented 10 months ago

This pull request has been automatically locked. If you believe you have found a related problem, please file a new issue (with a reprex: https://reprex.tidyverse.org) and link to this issue.