[GRASS-user] integer and discrete raster
veroandreo at gmail.com
Tue Sep 25 05:43:26 PDT 2018
See this related thread:
The method sum in r.series always returns DCELL. But maybe this is also a
case in which a check of data type could be done beforehand, so the result
keeps the original data type.
El mar., 25 sept. 2018 a las 10:51, Frank David (<frank.david at geophom.fr>)
> Hello all,
> I've done a sum with r.series from 8 rasters previously calculated with
> r.mapcalc. Each raster cell content is 0 or 1. So the sum raster cells
> should have 0 to 8. I was looking at r.category to set labels like "1 to
> 2", "3 to 4", etc. To see my raster values, I've done a r.describe, and the
> result surprised me :
> instead of :
> If I do int(value) with r.mapcalc in my first raster (value is integer),
> r.describe returns integer result as expected.
> Why r.describe return float values ? how they are calculated ? why I must
> make a int() on a integer to get an integer ?
> Since my values are integer, how can I force raster in CELL instead of
> DCELL ?
> Thanks to help me to understand this !
> grass-user mailing list
> grass-user at lists.osgeo.org
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the grass-user