R/archive/zzz.R

Defines functions .onLoad .onAttach

.onAttach <- function(libname, pkgname) {
  options(rgee.print.option = "simply")
}

.onLoad <- function(libname, pkgname) {
  # # if EARTHENGINE_PYTHON is defined then forward it to RETICULATE_PYTHON
  # earthengine_python <- Sys.getenv("EARTHENGINE_PYTHON", unset = NA)
  # if (!is.na(earthengine_python))
  #   Sys.setenv(RETICULATE_PYTHON = earthengine_python)

  # delay load earthengine-api
  # ee <<- reticulate::import("ee", delay_load = TRUE)
  #ee <<- reticulate::import("ee", delay_load = list(priority = 30))
  library(rgee)

}
r-tidy-remote-sensing/tidyrgee documentation built on April 9, 2023, 4:53 p.m.