GRASS logo

NAME

r.quantile.ref - Determines quantile for input value from reference raster map layers.

KEYWORDS

raster, aggregation, series, statistics, quantile

SYNOPSIS

r.quantile.ref
r.quantile.ref --help
r.quantile.ref [-z] input=name [reference=name[,name,...]] [file=name] output=name [range=lo,hi] [--overwrite] [--help] [--verbose] [--quiet] [--ui]

Flags:

-z
Do not keep files open
--overwrite
Allow output files to overwrite existing files
--help
Print usage summary
--verbose
Verbose module output
--quiet
Quiet module output
--ui
Force launching GUI dialog

Parameters:

input=name [required]
Name of input raster map
reference=name[,name,...]
List ofreference raster maps
file=name
Input file with one reference raster map name per line
output=name [required]
Name for output raster map
range=lo,hi
Ignore values outside this range

Table of contents

DESCRIPTION

r.quantile.ref computes for each pixel the quantile ranking of the input value against the reference maps: values of 0, 0.5 and 1.0 respectively indicate that the input value corresponds with the minimum, median or maximum of the reference values. A value of -1 is assigned if the input value is smaller than the minimum and a value of 2 is assigned if the input value is larger than the maximum.

r.quantile.ref can be regarded as the inverse of r.series method=quantile: while r.series calculates the value for a given quantile, r.quantile.ref calculates the quantile for a given value. This is useful to compare e.g. current environmental conditions to a time series of historical environmental conditions.

EXAMPLE

Create some reference rasters:
r.mapcalc "ref1 = 1"
r.mapcalc "ref2 = 2"
r.mapcalc "ref3 = 3"
r.mapcalc "ref4 = 5"
r.mapcalc "ref5 = 5"
r.mapcalc "ref6 = 5"
Create a test raster with cell value 4.5:
r.mapcalc "test = 4.5"
Get the quantile of the test raster for the reference maps:
r.quantile.ref input=test reference=ref1,ref2,ref3,ref4,ref5,ref6 output=test_quant
The quantile corresponding to the value 4.5 is 0.55. Create a test raster with cell value 5:
r.mapcalc "test = 5"
Get the quantile of the test raster for the reference maps:
r.quantile.ref input=test reference=ref1,ref2,ref3,ref4,ref5,ref6 output=test_quant
The quantile corresponding to the value 5 is 0.8.

SEE ALSO

r.quantile, r.series

AUTHOR

Markus Metz

SOURCE CODE

Available at: r.quantile.ref source code (history)

Latest change: Monday Jan 30 19:52:26 2023 in commit: cac8d9d848299297977d1315b7e90cc3f7698730


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

© 2003-2024 GRASS Development Team, GRASS GIS 8.4.1dev Reference Manual