Skip to content

Instantly share code, notes, and snippets.

@obrl-soil
obrl-soil / rgrass7-setup-win-osgeo4w.R
Last active March 14, 2024 20:41
rgrass7 and OsGeo4W on Windows - environment variables for R
# Source this file at the top of an R or Rmd file using rgrass7 together
# with GRASS installed via OSGeo4W (https://trac.osgeo.org/osgeo4w/) on a
# Windows machine.
# e.g. source(file.path(getwd(), 'rgrass7-setup-win-osgeo4w.R'))
# You can alternatively add the contents to a project-specific .Rprofile.
# Its better to set these variables in an R session rather than in System,
# especially if you have other GIS software like PostGIS installed, which has