R/aaa.R

Defines functions .onLoad

#' @import checkmate
#' @import data.table
#' @import methods
#' @import R6
NULL

.onLoad <- function(libname, pkgname) {
  suppressWarnings(onCRAN <- isTRUE(as.logical(as.numeric( # nolint
    Sys.getenv("_R_CHECK_EXAMPLE_TIMING_CPU_TO_ELAPSED_THRESHOLD_")
  ))))
  if (onCRAN) {
    setDTthreads(2L)
  }

  getOption("DTSgClone"             , options(DTSgClone              = TRUE      ))
  getOption("DTSgDeprecatedWarnings", options(DTSgDeprecatedWarnings = TRUE      ))
  getOption("DTSgFast"              , options(DTSgFast               = FALSE     ))
  getOption("DTSgFunbyApproach"     , options(DTSgFunbyApproach      = "base"    ))
  getOption("DTSgNA.status"         , options(DTSgNA.status          = "explicit"))
}
gisler/DTSg documentation built on Jan. 11, 2024, 4:59 a.m.