View source: R/lump_grass_prep.R
lump_grass_prep | R Documentation |
Takes raster data from a GRASS location and calculates elementary hillslopes, soil-vegetation-components, and Horton stream order using GRASS functions needed for further Landscape Unit deviation.
lump_grass_prep(mask = NULL, dem = NULL, lcov = NULL, soil = NULL,
watermask = NULL, imperviousmask = NULL, eha = NULL,
flowdir = NULL, flowacc = NULL, stream = NULL,
stream_horton = NULL, elevriv = NULL, distriv = NULL,
mask_corr = NULL, svc = NULL, dir_out = NULL, svc_ofile = NULL,
eha_thres = NULL, sizefilter = NULL, growrad = NULL,
keep_temp = F, overwrite = F, silent = F, addon_path = NULL,
things2do = c("eha", "river", "svc"))
mask |
Mask in GRASS location defining the catchment area. E.g. subbasin raster map. |
dem |
Digital elevation model in GRASS location used for delineation of environmental hillslope areas. Should be larger than the expected catchment, otherwise artefacts close to boundaries may occur. |
lcov |
Landcover / vegetation raster map in GRASS location. |
soil |
Soil raster map in GRASS location. |
watermask |
Raster in GRASS location masking water surfaces (value '1') from
other areas (value '0'). Map is used for |
imperviousmask |
The same as for |
eha |
Output: Name of Environmental Hillslope Areas (EHA) raster map exported into GRASS location. |
flowdir |
Output: Name of flow direction raster map exported into GRASS location. Provides the "aspect" for each cell measured counterclockwise from East. Multiplying positive values by 45 will give the direction in degrees that the surface runoff will travel from that cell; zero indicates a depression; negative values that surface runoff is leaving the defined region. |
flowacc |
Output: Name of flow accumulation raster map exported into GRASS location. Gives the number of upslope cells plus one. Negative values indicate surface runoff from outside the defined region. |
stream |
Output: Name of stream segments raster map exported into GRASS location. If you want to convert it into a vector map apply GRASS function r.thin beforehand! |
stream_horton |
Output: Name of stream segments raster map in Horton stream order exported into GRASS location. |
elevriv |
Output: Name of relative elevation raster map exported into GRASS
location. Provides the elevations above stream node in units of |
distriv |
Output: Name of distance to river raster map exported into GRASS location. Provides distances to stream node in number of grid cells. |
mask_corr |
DEPRECATED! Argument kept for backwards compatibility. |
svc |
Output: Name of Soil Vegetation Components raster map exported into
GRASS location; cross product of categories of |
dir_out |
Character string specifying output directory (will be created; nothing will be overwritten). |
svc_ofile |
Output: Name of file containing properties of |
eha_thres |
Integer specifying threshold for delineation of EHA in cells;
parameter for GRASS function r.watershed. This is a crucial parameter
affecting the size of delineated hillslopes and the degree of detail of the
landscape discretisation! As a rule of thumb, a value 10-100 times smaller
than |
sizefilter |
Integer specifying the minimum size of EHAs in hectares.
Smaller EHAs (possibly artefacts) will be removed. Parameter for
GRASS function r.reclass.area. If set to |
growrad |
Integer specifying growing radius (in raster cells) to remove
holes in the EHA raster resulting from cleaning of artefacts; parameter for
GRASS function r.grow. If set to |
keep_temp |
|
overwrite |
|
silent |
|
addon_path |
Character string giving the path to your locally installed
GRASS add-ons. Must only be given if necessary, see |
things2do |
|
Function returns nothing. Output raster files as specified in arguments (see above) are written into GRASS location.
Prepare GRASS location and necessary raster files in advance and start
GRASS session in R using initGRASS
.
Make sure that the GRASS functions r.stream.distance and r.stream.order
are available to your GRASS installation. If not, consider g.extension to
install add-ons. If you installed add-ons locally it might occur that from within R
the path to add-ons is not recognised. In such a case locate the local installation
path (in a GRASS terminal check g.extension -a
, echo $GRASS_ADDON_BASE
and which r.stream.distance
/ where r.stream.distance
, and specify the
absolute path to add-ons via argument addon_path
. In Windows, replace backslahes for slashes. For more information, see also
http://grasswiki.osgeo.org/wiki/AddOns/GRASS_7.
See GRASS documentation for further information on GRASS functions and parameters.
Tobias Pilz tpilz@uni-potsdam.de
Source code based on SHELL
and MATLAB
scripts of Till Francke.
lumpR package introduction with literature study and sensitivity analysis:
Pilz, T.; Francke, T.; Bronstert, A. (2017): lumpR 2.0.0: an R package facilitating
landscape discretisation for hillslope-based hydrological models.
Geosci. Model Dev., 10, 3001-3023, doi: 10.5194/gmd-10-3001-2017
Theory of LUMP:
Francke, T.; Guentner, A.; Mamede, G.; Mueller, E. N. and Bronstert, A (2008):
Automated catena-based discretization of landscapes for the derivation of
hydrological modelling units. International Journal of Geographical
Information Science, Informa UK Limited, 22(2), 111-132, DOI: 10.1080/13658810701300873
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.