## Not run:
# # Check the default RSAGA environment on your computer:
# myenv <- rsaga.env()
# myenv
# # SAGA data in C:/sagadata, binaries in C:/SAGA-GIS, modules in C:/SAGA-GIS/modules:
# myenv <- rsaga.env(workspace="C:/sagadata", path="C:/SAGA-GIS")
# # Unix: SAGA in /usr/bin (instead of the default /usr/local/bin),
# # and modules in /use/lib/saga:
# # myenv <- rsaga.env(path="/usr/bin")
# # Use the 'myenv' environment for SAGA geoprocessing:
# rsaga.hillshade("dem","hillshade",env=myenv)
# # ...creates (or overwrites) grid "C:/sagadata/hillshade.sgrd"
# # derived from digital elevation model "C:/sagadata/dem.sgrd"
#
# # Same calculation with different SAGA version:
# # (I keep several versions in SAGA-GIS_2.0.x folders:)
# myenv05 = rsaga.env(path = "C:/Progra~1/SAGA-GIS_2.0.5")
# rsaga.hillshade("dem","hillshade205",env=myenv05)
# ## End(Not run)
Run the code above in your browser using DataLab