Table of contents

GRASS GIS manual: r.li
GRASS logo

NAME

r.li - Toolset for multiscale analysis of landscape structure

KEYWORDS

raster, landscape structure analysis, diversity index, patch index

DESCRIPTION

The r.li suite is a toolset for multiscale analysis of landscape structure. It aims at implementing metrics as found in external software for quantitative measures of landscape structure like FRAGSTATS (McGarigal and Marks 1995).

The r.li suite offers a set of patch and diversity indices. It supports analysis of landscapes composed of a mosaic of patches, but, more generally, the modules work with any two-dimensional raster map whose cell values are integer (e.g., 1, 2) or floating point (e.g., 1.1, 3.2) values. The g.gui.rlisetup module has options for controlling the shape, size, number, and distribution of sampling areas used to collect information about the landscape structure. Sampling area shapes can be the entire map or a moving window of square, rectangular or circular shape. The size of sampling areas can be changed, so that the landscape can be analyzed at a variety of spatial scales simultaneously. Sampling areas may be distributed across the landscape in a random, systematic, or stratified-random manner, or as a moving window.

The r.li modules can calculate a number of measures that produce single values as output (e.g. mean patch size in the sampling area), as well as measures that produce a distribution of values as output (e.g. frequency distribution of patch sizes in the sampling area). The results are stored as raster maps.

All modules require configuration file which can be created by the g.gui.rlisetup module which is a GUI tool providing a convenient way to set all necessary parameters. This file can be used repetitively saving user from the need to specify all parameters over and over again.

NOTES

The general procedure to calculate an index from a raster map is two-fold:
  1. run g.gui.rlisetup: create a configuration file selecting the parts of raster map to be analyzed. This file allows re-running an analysis easily. It is stored on Windows in the directory C:\Users\userxy\AppData\Roaming\GRASS7\r.li\, on GNU/Linux in $HOME/.grass7/r.li/.
  2. run one or more of the r.li.[index] modules (e.g., r.li.patchdensity) to calculate the selected index using on the areas selected on configuration file.

EXAMPLES

Calculate a patch density index on the entire 'geology' raster map in the Spearfish sample dataset, using a 5x5 moving window:
  1. CREATE A NEW CONFIGURATION FILE
    1. run
        g.gui.rlisetup
      
    2. The main g.gui.rlisetup window is displayed, click on "New"
    3. The new configuration window is now displayed, enter the configuration file name (e.g., "my_conf", do not use absolute paths) Now the new configuration window is displayed. Enter the configuration file name (e.g., "my_conf", do not use absolute paths) and the name of raster map (e.g., "geology"). The other fields are not needed for this configuration.
    4. Click on "Setup sampling frame", select "Whole map layer" and click "OK"
    5. Click on "Setup sampling areas", select "Moving window" and click "OK"
    6. Click on "Use keyboard to enter moving window dimension"
    7. Select "Rectangle" and enter 5 in the "height" and "width" fields
    8. Click on "Save settings"
    9. Close the g.gui.rlisetup window
  2. CALCULATE PATCHDENSITY INDEX
    1. set the region settings to the "geology" raster map:
        g.region raster=geology -p
      
    2. run r.li.patchdensity:
        r.li.patchdensity input=geology conf=my_conf out=patchdens
      
The resulting patch density is stored in "patchdens" raster map. You can verify the result for example with contour lines:
  r.contour in=patchdens out=patchdens step=5
  d.rast patchdens
  d.vect -c patchdens
Note that if you want to run another index with the same area configuration, you don't have to create another configuration file. You can also use the same area configuration file on another map. The program rescale it automatically. For instance if you have selected a 5x5 sample area on 100x100 raster map, and you use the same configuration file on a 200x200 raster map, then the sample area is 10x10.

SEE ALSO

GUI tools: Patch indices: Diversity indices: Core library:

ADDING NEW INDICES

New indices can be defined and implemented by any C programmer, without having to deal with all basic functions (IO etc.). The computing architecture and the functions are clearly separated, thus allowing an easy expandability. Every index is defined separately, placed in a directory along with its Makefile for compiling it and a file <module_name>.html which describes the index including a simple example of use. See r.li.daemon for more information about development.

REFERENCES

AUTHORS

Claudio Porta and Lucio Davide Spano, students of Computer Science, University of Pisa (Italy).
Commission from Faunalia Pontedera (PI)

Partially rewritten by Markus Metz

Last changed: $Date: 2017-11-12 05:14:46 -0800 (Sun, 12 Nov 2017) $


Main index | Topics index | Keywords index | Graphical index | Full index

© 2003-2017 GRASS Development Team, GRASS GIS 7.5.svn Reference Manual