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 Oct. 16, 2024, 10:23 p.m.