r.mapcalc and the neighborhood modifier
Jim Westervelt
westerve at zorro.cecer.army.mil
Fri Sep 25 13:55:11 EDT 1992
# is there an available example of r.mapcalc that uses the
# neighborhood modifier, so that the result of the target
# cell depends on the weighted values of the 8 surrounding
# cells ?
# if there is could i get a copy ?
#
# Tom Nelson
Off the top of my head (that is, no guarantees) the following might be
a simple example to demonstrate:
r.mapcalc < rules
rules contains:
average=elevation[-1,-1]+elevation[-1,0]+elevation[-1,1] \
+elevation[ 0,-1]+elevation[ 0,0]+elevation[ 0,1] \
+elevation[ 1,-1]+elevation[ 1,0]+elevation[ 1,1] / 9
More information about the grass-user
mailing list