[GRASS-dev] r.statistics method=distribution: missing/wrong statistics for base cat values <= 0

Hi All,

Today I downloaded GRASS 6.4.2 from SVN and noticed that an earlier reported (see [0]) r.statistics bug is still present: missing/wrong statistics for base cat values <= 0. My observations are:

a) base cat value is negative -> statistics = 'inf'
b) base cat value is 0 -> no statistics generated

See some sample data at [1], and resulting statistics at [2].

Are there any plans to change behaviour of r.statistics ?

Regards, Hermann

[0] Earlier reports related on the same issue

http://lists.osgeo.org/pipermail/grass-user/2009-October/052602.html
http://trac.osgeo.org/grass/ticket/763

[1] Sample data

$ head map?.asc

==> map1.asc <==
nrows 3
ncols 3
xllcorner 0
yllcorner 0
cellsize 1
-1 -2 -3
  0 0 0
  1 2 3

==> map2.asc <==
nrows 3
ncols 3
xllcorner 0
yllcorner 0
cellsize 1
  0 -1 -2
  0 1 2
  1 2 3

$ for f in map?.asc; do r.in.gdal -o $f out=${f%.asc}; done
$ g.region rast=map1

[2] r.statistics results

$ r.statistics base=map1 cover=map2 method=distribution

       -3 -2 inf
       -2 -1 inf
       -1 0 inf
        1 1 100.000000
        2 2 100.000000
        3 3 100.000000