On Aug 12, 2008, at 10:29 PM, Glynn Clements wrote:
Michael Barton wrote:
Currently, due to its history, GRASS has various ways of
designating a
range of values.
In raster displays (d.rast) ranges are expressed as 'n-n';
for color tables, they are implied but not explicitly given;
for raster reclass maps (r.reclass), they are expressed as 'n thru n'
for raster recode (r.recode), they are expressed as 'n:n';
for vector reclass (actually a recode, v.reclass), ranges are
expressed in SQL syntax
At least for rasters, I'd like to suggest that we standardize range
notation.
I recommend 'n-n'. It is compact, widely recognized, and doesn't
use a
misspelled english word ("thru"). The syntax 'n:n' is used in some
programming, but not a lot beyond that.
One issue with "m-n" is that it could be quite easy to inadvertently
write code which doesn't handle negative values correctly, e.g.
"-10--5". IMHO, it's also less clear than "-10:-5".
OK. What about "m to n"?
Michael
_______________________________________________
grass-dev mailing list
[email protected]
http://lists.osgeo.org/mailman/listinfo/grass-dev