R/zzz.R

Defines functions .onLoad

.onLoad <- function(...) {
  cmdstan_version <- cmdstanr::cmdstan_version(error_on_NA = FALSE)
  if (is.null(cmdstan_version)) {
    #stop("No CmdStan installation found. Run cmdstanr::install_cmdstan() to install.", call. = FALSE)
    cmdstanr::check_cmdstan_toolchain(fix = TRUE)
    cmdstanr::install_cmdstan()
  }
}
netZoo/netZooR documentation built on June 8, 2024, 6:20 a.m.