Provided by: grass-doc_7.6.1-3_all

**NAME**

r.resamp.stats- Resamples raster map layers to a coarser grid using aggregation.

**KEYWORDS**

raster, resample

**SYNOPSIS**

r.resamp.statsr.resamp.stats--helpr.resamp.stats[-nw]input=nameoutput=name[method=string] [quantile=float] [--overwrite] [--help] [--verbose] [--quiet] [--ui]Flags:-nPropagate NULLs-wWeight according to area (slower)--overwriteAllow output files to overwrite existing files--helpPrint usage summary--verboseVerbose module output--quietQuiet module output--uiForce launching GUI dialogParameters:input=name[required]Name of input raster mapoutput=name[required]Name for output raster mapmethod=stringAggregation method Options:average,median,mode,minimum,maximum,range,quart1,quart3,perc90,sum,variance,stddev,quantile,count,diversityDefault:averagequantile=floatQuantile to calculate for method=quantile Options:0.0-1.0Default:0.5

**DESCRIPTION**

r.resamp.statsfills a grid cell (raster) matrix with aggregated values generated from a set of input layer data points. Without the-wswitch, the aggregate is computed over all of the input cells whose centers lie within the output cell. With the-wswitch, the aggregate uses the values from all input cells which intersect the output cell, weighted according to the proportion of the source cell which lies inside the output cell. This is slower, but produces a more accurate result.

**NOTES**

Resampling modules (r.resample,r.resamp.stats,r.resamp.interp,r.resamp.rst) resample the map to match the current region settings. The notion of weighting doesn’t make any sense for the min and max aggregates. However, the-wflag still has significance in that, when multiple destination cells overlap a source cell, the source cell is included in the calculation of all of the destination cells.

**EXAMPLE**

Resample elevation raster map to a lower resolution (from 6m to 20m; North Carolina sample dataset): g.region raster=el_D782_6m -p g.region res=20 -ap # from 6m to 20m: weighted resampling -w r.resamp.stats -w input=el_D782_6m output=el_D782_20mResamplingof6mDEM(left)to20mDEM(right)withweightedresampling(subset)

**SEE** **ALSO**

g.region,r.resample,r.resamp.rst,r.resamp.filter,r.resamp.interp,r.neighborsOverview: Interpolation and Resampling in GRASS GIS Examples how statistical functions are applied can be found in the r.neighbors module documentation.

**AUTHOR**

Glynn ClementsLastchanged:$Date:2017-01-0809:46:20+0100(Sun,08Jan2017)$

**SOURCE** **CODE**

Available at: r.resamp.stats source code (history) Main index | Raster index | Topics index | Keywords index | Graphical index | Full index © 2003-2019 GRASS Development Team, GRASS GIS 7.6.1 Reference Manual