[GRASS-dev] [GRASS GIS] #3184: v.vect.stats: errors in counts and statistics

GRASS GIS trac at osgeo.org
Tue Oct 25 06:06:07 PDT 2016


#3184: v.vect.stats: errors in counts and statistics
-------------------------+--------------------------
  Reporter:  veroandreo  |      Owner:  grass-dev@…
      Type:  defect      |     Status:  new
  Priority:  normal      |  Milestone:  7.2.0
 Component:  Vector      |    Version:  svn-trunk
Resolution:              |   Keywords:  v.vect.stats
       CPU:  x86-64      |   Platform:  Linux
-------------------------+--------------------------

Comment (by mmetz):

 Replying to [comment:13 veroandreo]:
 > Replying to [comment:12 mmetz]:
 > > I have uploaded a patch (v_vect_stats_unique_cats_no_half.diff​) that
 correctly removes duplicate cats (similar to
 v_vect_stats_unique_cats.2.diff) and additionally eliminates the usage of
 half (adding 0.5 to the result). This half makes only sense if the result
 is to be converted to integer and if the result is a positive number. The
 result is always floating point, therefore adding 0.5 causes wrong
 results.
 >
 > Thanks Markus! I applied the patch and tested with Moritz's test data
 and examples, and also with my own data. Counts are fine and also stats :)

 This is a bugfix and should be backported to the G7 release branches. Too
 late for 7.2?

--
Ticket URL: <https://trac.osgeo.org/grass/ticket/3184#comment:14>
GRASS GIS <https://grass.osgeo.org>



More information about the grass-dev mailing list