r3.neighbors(1grass)
β¨ r3.neighbors (1grass) β¨
okay bestie, this is the GRASS User's Manual page for r3.neighbors, and it's literally the 3D voxel glow-up module. no cap.
πΈ NAME πΈ
r3.neighbors β makes each voxel value a function of the values assigned to the voxels around it, and stores new voxel values in an output 3D raster map. it's giving "main character voxel, but make it a team effort" π
π KEYWORDS π
raster3d, algebra, voxel, statistics, aggregation, neighbor, focal statistics, filter
π¦ SYNOPSIS π¦
r3.neighbors
r3.neighbors --help
r3.neighbors input=name output=name method=string [quantile=float]
window=x,y,z [--overwrite] [--help] [--verbose] [--quiet] [--ui]
π© Flags
--overwriteβ allow output files to overwrite existing files (yes bestie, it will absolutely eat what's already there, so be sure)--helpβ print usage summary--verboseβ verbose module output--quietβ quiet module output--uiβ force launching GUI dialog
π Parameters
input=name[required] β name of input 3D raster mapoutput=name[required] β name for output 3D raster mapmethod=string[required] β aggregate operation- Options:
average,median,mode,minimum,maximum,range,stddev,sum,count,variance,diversity,interspersion,quart1,quart3,perc90,quantile
- Options:
quantile=floatβ quantile to calculate formethod=quantile- Options:
0.0-1.0
- Options:
window=x,y,z[required] β the size of the window in x, y and z direction; values must be odd integer numbers, eg:3,3,3
π DESCRIPTION π
r3.neighbors looks at each voxel in a 3D raster input map layer, and examines the values assigned to the voxel in a user-defined "neighborhood" around it. it outputs a new 3D raster map in which each voxel is assigned a value that is a (user-specified) function of the values in that voxel's neighborhood. for example, each voxel in the output map might be assigned a value equal to the average of the values appearing in its 3 x 3 x 3 voxel "neighborhood" in the input map layer. iconic behavior honestly.
π OPTIONS π
you must specify the names of the 3D raster map layers to be used for input and output, the method used to analyze neighborhood values (i.e., the neighborhood function or operation to be performed), and the moving window of the neighborhood. no skipping, bestie, it's required-required.
Neighborhood Operation Methods: the neighborhood operators determine what new value a center voxel in a neighborhood will have after examining values inside its neighboring voxels. each voxel in a 3D raster map layer becomes the center voxel of a neighborhood as the neighborhood window moves from voxel to voxel throughout the map layer. r3.neighbors can perform the following operations:
averageβ the average value within the neighborhood.medianβ the value found half-way through a list of the neighborhood's values, when these are ranged in numerical order.modeβ the most frequently occurring value in the neighborhood.minimumβ the minimum value within the neighborhood.maximumβ the maximum value within the neighborhood.rangeβ the range value within the neighborhood.stddevβ the statistical standard deviation of values within the neighborhood.sumβ the sum of values within the neighborhood.varianceβ the statistical variance of values within the neighborhood.diversityβ the number of different values within the neighborhood.interspersionβ the percentage of voxels containing values which differ from the values assigned to the center voxel in the neighborhood, plus 1.
Neighborhood Size: the neighborhood moving window specifies which voxel surrounding any given voxel fall into the neighborhood for that voxel. the window must be three comma separated odd integers. the dimension order is: x,y,z. for example: the parameter window=3,3,3 specifies a moving window (a cube) with 27 voxel. π§ so cute, so cubic.
π₯ NOTES π₯
the r3.neighbors program works in the current geographic region. it is recommended, but not required, that the 3D resolution of the geographic region be the same as that of the 3D raster map layer.
r3.neighbors doesn't propagate NULLs, but computes the aggregation over the non-NULL voxels in the neighborhood. slay, honestly β the empty ones just sit it out.
π SEE ALSO π
g.region, r.neighbors, r3.mapcalc, r3.stats, r3.support
π AUTHOR π
Soeren Gebbert
π«Ά SOURCE CODE π«Ά
Available at: r3.neighbors source code (history)
Latest change: Friday Feb 07 19:16:09 2025 in commit: a82a39f673b97fafcfce1604dc3e6015cb96487a
Main index | 3D raster index | Topics index | Keywords index | Graphical index | Full index
Β© 2003-2026 GRASS Development Team, GRASS 8.5.0 Reference Manual
and that's the whole page, bestie β¨ you just read the GRASS 8.5.0 version of r3.neighbors(1grass) β yeah, the footer said exactly that β and the latest change on record is dated Friday Feb 07 19:16:09 2025 π go aggregate some voxels, you absolute icon π
π¦ where this page comes from
- alpine 3.24: grass-gis-doc 8.5.0-r1 Β· GPL-2.0-or-later
- ubuntu stonking: grass-doc 8.5.0-1ubuntu1 Β· GPL-2.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms