[GRASS-dev] Re: [GRASS GIS] #335: export floats and doubles with correct precision

GRASS GIS trac at osgeo.org
Fri Dec 5 21:29:57 EST 2008


#335: export floats and doubles with correct precision
--------------------------+-------------------------------------------------
  Reporter:  hamish       |       Owner:  grass-dev at lists.osgeo.org
      Type:  task         |      Status:  new                      
  Priority:  critical     |   Milestone:  6.4.0                    
 Component:  default      |     Version:  unspecified              
Resolution:               |    Keywords:  precision                
  Platform:  Unspecified  |         Cpu:  Unspecified              
--------------------------+-------------------------------------------------
Comment (by hamish):

 v.univar too,

 {{{
 g.copy vect=archsites,tmp_arch
 v.db.addcol tmp_arch column='x double, y double'
 v.to.db tmp_arch option=coor columns=x,y

 eval `v.univar -g tmp_arch column=x type=point | grep -w mean`
 X_MEAN=$mean

 eval `v.univar -g tmp_arch column=y type=point | grep -w mean`
 Y_MEAN=$mean

 echo "Center of point cloud: $X_MEAN, $Y_MEAN"
 }}}

 Center of point cloud: 598326, 4.92146e+06

 would be nice for y coord to be intact (ie preserve 3 digits to the right
 of the decimal point (mm))


 Hamish

-- 
Ticket URL: <https://trac.osgeo.org/grass/ticket/335#comment:3>
GRASS GIS <http://grass.osgeo.org>


More information about the grass-dev mailing list