Description Usage Arguments Details Value Author(s) Examples
Function that initializes environment, pathes, SAGA, GRASS7 and GDAL support via gdalUtils. *NOTE* you probably have to customize some settings according to your personal installation folders.
1 | initRGIS(fname.control,)
|
root.dir |
project directory |
working.dir |
runtime directory |
fndem |
name of a (DEM) GDAL format raster file |
rasterParam |
a rasterobject link |
The concept is very straightforward but for an all days usage pretty helpful. You need to provide a GDAL conform raster file, a raster object or you may download SRTM data with getGeoData. This settings will be used to initialize a temporary but static rgrass7 environment. Additionally RSAGA and gdalUtils are initialized and checked. During the rsession you will have full access to GRASS7 and SAGA via the wrapper packages. .
initRGIS initializes the usage of GRASS7 RSAGA 2.12+ and gdalUtil
it returns the RSAGA env, the GRASS env and the gdalUtils status
Chris Reudenbach reudenbach@gis-ma.org
1 2 3 4 5 6 7 8 9 10 | #### Examples how to use RSAGA and GRASS bindings from R
# full call using getGeodata
envGIS<- initRGIS <- function(root.dir=tempdir(),working.dir='cost',fndem=getGeoData("SRTM",xtent=c(49,49,11,11)))
# initialisation with an existing raster object
envGIS<- initRGIS("~/proj/tester",'cost',fndem=NULL,rasterParam = outraster)
# init with an local GDAL file
envGIS<- initRGIS("~/proj/tester",'cost',"~/proj/runbeetle/srtm_43_01.tif")
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.