R/zzz.R

Defines functions is_attached .onAttach

.onAttach <- function(...) {
  needed <- core[!is_attached(core)]
  if (length(needed) == 0) {
    return()
  }

  tidymodels_attach()

  if (!"package:conflicted" %in% search()) {
    x <- tidymodels_conflicts()
    msg(tidymodels_conflict_message(x), startup = TRUE)
  }
}

is_attached <- function(x) {
  paste0("package:", x) %in% search()
}

Try the tidymodels package in your browser

Any scripts or data that you put into this service are public.

tidymodels documentation built on Aug. 25, 2023, 1:07 a.m.