r.mapcalc

charnotw charnotw at helios.aston.ac.uk
Tue Nov 12 14:04:14 EST 1996


r.mapcalc should do all the things you want, 

some names are variables e.g.

r.mapcalc "output=eval(const=6.5,raster_name*const)"

and though is logic control

the syntax is

r.mapcalc "output=if(condition,action_if_true,action_if_false)"

e.g.

r.mapcalc "output=if(raster1==7 && raster2==3,1,0)"

ifs can be embedded, however there is no other kind 
of flow control like loops.

there should be some documention under the g.manual 
command e.g.

g.manual r.mapcalc




cheers Tom



More information about the grass-user mailing list