R/zzz.r

Defines functions .onLoad

#' @importFrom reticulate import
.onLoad <- function(libname, pkgname) {
  # import modules
  arcpy <<- import("arcpy", delay_load = TRUE)
  arcgis <<- import("arcgis", delay_load = TRUE)
  # look for ArcGIS Pro by default if option not defined
  if (is.null(getOption("arcpy.pro"))) {
    options(arcpy.pro = TRUE)
  }
}
mkoohafkan/arcpy documentation built on Aug. 9, 2020, 2:51 p.m.