[GRASS-SVN] r62249 - grass/branches/releasebranch_7_0/raster/r.univar

svn_grass at osgeo.org svn_grass at osgeo.org
Mon Oct 13 19:57:21 PDT 2014


Author: wenzeslaus
Date: 2014-10-13 19:57:21 -0700 (Mon, 13 Oct 2014)
New Revision: 62249

Modified:
   grass/branches/releasebranch_7_0/raster/r.univar/r.univar.html
   grass/branches/releasebranch_7_0/raster/r.univar/r.univar_main.c
   grass/branches/releasebranch_7_0/raster/r.univar/r3.univar.html
   grass/branches/releasebranch_7_0/raster/r.univar/r3.univar_main.c
Log:
r.univar: include sum, put statistics to description, improve manual (backport of r62185 and r62186)

Modified: grass/branches/releasebranch_7_0/raster/r.univar/r.univar.html
===================================================================
--- grass/branches/releasebranch_7_0/raster/r.univar/r.univar.html	2014-10-14 01:39:11 UTC (rev 62248)
+++ grass/branches/releasebranch_7_0/raster/r.univar/r.univar.html	2014-10-14 02:57:21 UTC (rev 62249)
@@ -2,8 +2,8 @@
 
 <em>r.univar</em> calculates the univariate statistics of one or several raster
 map(s). This includes the number of cells counted, minimum and maximum cell
-values, range, arithmetic mean, population variance, standard deviation, and 
-coefficient of variation. Statistics are calculated separately for every
+values, range, arithmetic mean, population variance, standard deviation,
+coefficient of variation, and sum. Statistics are calculated separately for every
 category/zone found in the <b>zones</b> input map if given.
 If the <b>-e</b> extended statistics flag is given the 1st quartile, median,
 3rd quartile, and given <b>percentile</b> are calculated.

Modified: grass/branches/releasebranch_7_0/raster/r.univar/r.univar_main.c
===================================================================
--- grass/branches/releasebranch_7_0/raster/r.univar/r.univar_main.c	2014-10-14 01:39:11 UTC (rev 62248)
+++ grass/branches/releasebranch_7_0/raster/r.univar/r.univar_main.c	2014-10-14 02:57:21 UTC (rev 62249)
@@ -101,8 +101,13 @@
     G_add_keyword(_("statistics"));
     G_add_keyword(_("univariate statistics"));
     G_add_keyword(_("zonal statistics"));
+
+    module->label =
+	_("Calculates univariate statistics from the non-null cells of a raster map.");
     module->description =
-	_("Calculates univariate statistics from the non-null cells of a raster map.");
+	_("Statistics include number of cells counted, minimum and maximum cell"
+	    " values, range, arithmetic mean, population variance, standard deviation,"
+	    " coefficient of variation, and sum.");
 
     /* Define the different options */
     set_params();

Modified: grass/branches/releasebranch_7_0/raster/r.univar/r3.univar.html
===================================================================
--- grass/branches/releasebranch_7_0/raster/r.univar/r3.univar.html	2014-10-14 01:39:11 UTC (rev 62248)
+++ grass/branches/releasebranch_7_0/raster/r.univar/r3.univar.html	2014-10-14 02:57:21 UTC (rev 62249)
@@ -1,9 +1,9 @@
 <h2>DESCRIPTION</h2>
 
-<em>r3.univar</em> calculates the univariate statistics for raster3d maps.
+<em>r3.univar</em> calculates the univariate statistics for a 3D raster map.
 This includes the number of cells counted, minimum and maximum cell values,
-range, arithmetic mean, population variance, standard deviation, and 
-coefficient of variation. Statistics are calculated separately for every
+range, arithmetic mean, population variance, standard deviation,
+coefficient of variation, and sum. Statistics are calculated separately for every
 category/zone found in the <b>zones</b> input map if given.
 If the <b>-e</b> extended statistics flag is given the 1st quartile, median,
 3rd quartile, and given <b>percentile</b> are calculated.
@@ -31,6 +31,19 @@
 calculating percentiles with large maps.
 -->
 
+<h2>EXAMPLE</h2>
+
+Computing univariate statistics of a 3D raster with randomly generated values:
+
+<div class="code"><pre>
+# generate random map
+r3.mapcalc "random_0_1 = rand(0., 1)" -s
+
+# compute univariate statistics
+r3.univar map=random_0_1
+</pre></div>
+
+
 <h2>TODO</h2>
 
 <i>mode, skewness, kurtosis</i>

Modified: grass/branches/releasebranch_7_0/raster/r.univar/r3.univar_main.c
===================================================================
--- grass/branches/releasebranch_7_0/raster/r.univar/r3.univar_main.c	2014-10-14 01:39:11 UTC (rev 62248)
+++ grass/branches/releasebranch_7_0/raster/r.univar/r3.univar_main.c	2014-10-14 02:57:21 UTC (rev 62249)
@@ -99,8 +99,12 @@
     G_add_keyword(_("statistics"));
     G_add_keyword(_("univariate statistics"));
 
+    module->label =
+	_("Calculates univariate statistics from the non-null cells of a 3D raster map.");
     module->description =
-	_("Calculates univariate statistics from the non-null 3d cells of a raster3d map.");
+	_("Statistics include number of cells counted, minimum and maximum cell"
+	    " values, range, arithmetic mean, population variance, standard deviation,"
+	    " coefficient of variation, and sum.");
 
     /* Define the different options */
     set_params();



More information about the grass-commit mailing list