r.pi.nlm
Creates a random generated map with values 0 or 1by given landcover and fragment count.
r.pi.nlm [-r] [input=name] output=name [keyval=integer] [nullval=integer [,integer,...]] [landcover=float] [sharpness=float] [seed=integer] [title="phrase"] [--overwrite] [--verbose] [--quiet] [--qq] [--ui]
Example:
r.pi.nlm output=name
grass.script.run_command("r.pi.nlm", input=None, output, keyval=None, nullval=None, landcover=None, sharpness=None, seed=None, title=None, flags=None, overwrite=False, verbose=False, quiet=False, superquiet=False)
Example:
gs.run_command("r.pi.nlm", output="name")
Parameters
input=name
Name of input raster map
output=name [required]
Name for output raster map
keyval=integer
Value of a category from the input file to measure desired landcover
nullval=integer [,integer,...]
Values marking areas from the input file, which are to be NULL in the resulting map
landcover=float
Landcover in percent
sharpness=float
Small values produce smooth structures, great values produce sharp, edgy structures - Range [0-1]
seed=integer
Seed for random number generator
title="phrase"
Title for resultant raster map
-r
Print report to stdout
--overwrite
Allow output files to overwrite existing files
--help
Print usage summary
--verbose
Verbose module output
--quiet
Quiet module output
--qq
Very quiet module output
--ui
Force launching GUI dialog
input : str, optional
Name of input raster map
Used as: input, raster, name
output : str, required
Name for output raster map
Used as: output, raster, name
keyval : int, optional
Value of a category from the input file to measure desired landcover
nullval : int | list[int] | str, optional
Values marking areas from the input file, which are to be NULL in the resulting map
landcover : float, optional
Landcover in percent
sharpness : float, optional
Small values produce smooth structures, great values produce sharp, edgy structures - Range [0-1]
seed : int, optional
Seed for random number generator
title : str, optional
Title for resultant raster map
Used as: "phrase"
flags : str, optional
Allowed values: r
r
Print report to stdout
overwrite: bool, optional
Allow output files to overwrite existing files
Default: False
verbose: bool, optional
Verbose module output
Default: False
quiet: bool, optional
Quiet module output
Default: False
superquiet: bool, optional
Very quiet module output
Default: False
DESCRIPTION
Creates a random generated map with values 0 or 1" "by given landcover and agglomeration value.
NOTES
Related to r.pi.nlm.circ but using fractal landscapes instead of circular growth. Per default the size of the whole region is used for generating a random landscape, this can be constraint by assigning a class in a raster map with acts as mask for the generation of the random landscape (nullval). The landcover can be set manually, randomly or be taken from the input class coverage. The agglomeration level (sharpness) can be set manually or randomly. If similar random landscape with differing e.g. percentage coverage should be generated, then the seed can be set using any number and reused for any subsequent analysis.
EXAMPLE
An example for the North Carolina sample dataset: A random landscape with random percentage coverage and agglomeration factor:
r.pi.nlm output=nlm.1 landcover=50
A random landscape is generated using the percentage coverage of class 5. The agglomeration factor is set randomly:
r.pi.nlm input=landclass96 output=nlm.2 keyval=5
SEE ALSO
r.pi.nlm.circ, r.pi.nlm.stats, r.pi
AUTHORS
Programming: Elshad Shirinov
Scientific concept: Dr. Martin Wegmann
Department of Remote Sensing
Remote Sensing and Biodiversity Unit
University of Wuerzburg, Germany
Port to GRASS GIS 7: Markus Metz
SOURCE CODE
Available at: r.pi.nlm source code
(history)
Latest change: Thursday Feb 20 13:02:26 2025 in commit 53de819