My understanding of the format for the if() operator with 4 parameters is that the result is the third parameter only when the first parameter equals zero. The GRASS MASK in your expression probably has only values of 1 and null, so the result will always be either parameter 1, or null.
In addtion, r.mapcalc would honor the MASK anyway, so it's not necessary to include it in the expression. Looking at your expression, the second parameter gives a boolean result, so maybe the following might give you what you want: (Also watch out map names with a dot '.') r.mapcalc "pr2_pass00 = if (curvt_cat == 1 && curvp_cat == 3 && asp_cat == 3 && slp_cat == 1 && jeo == 6 ,51, null() )" --overwrite -- View this message in context: http://osgeo-org.1560.x6.nabble.com/I-can-not-get-expected-value-with-r-mapcalc-tp5290749p5290795.html Sent from the Grass - Users mailing list archive at Nabble.com. _______________________________________________ grass-user mailing list [email protected] http://lists.osgeo.org/mailman/listinfo/grass-user
