arc.env: Get geoprocessing environment settings

arc.envR Documentation

Get geoprocessing environment settings

Description

Geoprocessing environment settings are additional parameters that affect a tool's results. Unlike parameters, they are not directly input as values. Instead, they are values configured in a separate dialog box, and then and interrogated and used by the script when run.

Usage

arc.env()

Details

The geoprocessing environment can control a variety of attributes relating to where data is stored, the extent and projection of analysis outputs, tolerances of output values, and parallel processing, among other attributes. Commonly used environment settings include workspace, which controls the default location for geoprocessing tool inputs and outputs. See the topics listed under "References" for details on the full range of environment settings that Geoprocessing scripts can utilize.

Value

return enviroment list

References

Note

  • This function is only available from within an ArcGIS session. Usually, it is used to get local Geoprocessing tool environment settings within the executing tool.

  • This function can only read current geoprocessing settings. Settings, such as the current workspace, must be configured in the calling Geoprocessing script, not within the body of the R script.

Examples

## Not run: 
  tool_exec <- function(in_para, out_params)
  {
    env = arc.env()
    wkspath <- env$workspace
    ...
    return(out_params)
  }

## End(Not run)

R-ArcGIS/r-bridge documentation built on May 3, 2024, 9:47 a.m.