R/zzz.R

Defines functions .onLoad .onAttach

.onAttach <- function(...) {
  if(interactive()) {
    packageStartupMessage("This is Cloudstan-R version ", utils::packageVersion("cloudstanr"))
    packageStartupMessage("- Most of 'cmdstanr' functions are exported, this library acts only as proxy.")
    packageStartupMessage("  Use it the same way as you would 'cmdstanr' directly.")
    packageStartupMessage("- Use login_*() to authenticate with the platform.")
    packageStartupMessage("- Models compiled with the remote executor can only be sampled remotely and vice versa.")
  }

  set_cloudstan_sys_env()
}

.onLoad <- function(...) {
  if(!is_latest_version()) {
    install()
  }
}
uroshercog/cloudstan-r documentation built on Dec. 23, 2021, 2:03 p.m.