[GRASS-user] Some issues with r.mapcalc

Fulvio Mastrogiovanni fulvio.mastrogiovanni at unige.it
Wed Apr 1 07:44:47 EDT 2009


Hi everyone,

I hope you can help me in solving this issue. Basically, what I want to do is to
create a new raster map whose cells are simply given by the "or" of other two
maps (possibly for specific categories), as follows:

r.mapcalc test=if(vegcover==1 || railroads==1)

However, maps like railroads are null() when not equal to 1. The resulting map
"test" is null() wherever cells in railroads are null(), therefore making
null() also cells where vegcover is 1.

How can I solve this issue?

Thanks!

Fulvio


-- 
Fulvio Mastrogiovanni
DIST|University of Genova|Italy

Email: fulvio.mastrogiovanni at unige.it
WWW: http://www.laboratorium.dist.unige.it/~fulvio/
Phone: (+39)0103532801

"Chi è abile nel sortire bizzarri stratagemmi è inesauribile come il
Cielo, la Terra e i grandi fiumi. Giunto al termine riparte, come il
Sole e la Luna; dopo morto rinasce, come le quattro stagioni."


More information about the grass-user mailing list