g.stats.pg(1)		      Grass User's Manual		 g.stats.pg(1)



NNAAMMEE
       _g_._s_t_a_t_s_._p_g  - Generate a range of simple statistics for the values in a
       database column. (GRASS-RDBMS General Interface Program)

SSYYNNOOPPSSIISS
       gg..ssttaattss..ppgg

       gg..ssttaattss..ppgg hheellpp

       gg..ssttaattss..ppgg [[--vvff]] ttaabbllee_=_n_a_m_e ccoolluummnn_=_n_a_m_e [wwhheerree_=_c_l_a_u_s_e]

DDEESSCCRRIIPPTTIIOONN
       _g_._s_t_a_t_s_._p_g generates a series of simple statistics for a numeric column
       in  the	specified  table  of the currently selected database. The cur-
       rently selected database is identified by the GRASS  environment  vari-
       able  $PG_DBASE	which  is  set	using the command _g_._s_e_l_e_c_t_._p_g. If this
       environment variable is not set the program terminates with  a  message
       to the user.  _g_._s_t_a_t_s_._p_g generates statistics for any numeric column in
       the table specified by the user. To identify the data types  for  indi-
       vidual  columns	in  a table in the currently selected database use the
       command _g_._c_o_l_u_m_n_._p_g with the _-_v flag. Statistics generated for the col-
       umn include count, sum, average, minimum value and maximum value.

CCOOMMMMAANNDD LLIINNEE OOPPTTIIOONNSS
   PPaarraammeetteerrss::
       ttaabbllee==ddaattaabbaasseettaabblleennaammee
	   Name of table in currently selected database.

       ccoolluummnn==ddaattaabbaasseeccoolluummnnnnaammee
	   Column in [table] which is numeric in type.

	   wwhheerree_=ccllaauussee Clause to select only some records from table


   FFllaaggss::
       --vv Verbose output

       --ff Use frequencies instead of min, max, mean


       EEXXAAMMPPLLEE

       _g_._s_t_a_t_s_._p_g _t_a_b_l_e_=_u_t_m _c_o_l_u_m_n_=_u_k_f_a_c_t

       Statistics for column: ukfact
	       171
	       sum
	       47.67
	       avg
	       0.28
	       max
	       0.49
	       min
	       0.00



       BBUUGGSS
       None known.


       NNOOTTEE
       This program requires the Postgres database software.


       SSEEEE AALLSSOO
       _g_._s_e_l_e_c_t_._p_g_,
       _d_._r_a_s_t_._p_g_,
       _d_._v_e_c_t_._p_g_,
       _d_._w_h_a_t_._s_._p_g_,
       _r_._r_e_c_l_a_s_s_._p_g_,
       _v_._r_e_c_l_a_s_s_._p_g


       AAUUTTHHOORR
       Original  Informix  SQL-tools:  James  A.  Farley,  Wang  Song,	and W.
       Fredrick
       Limp University of Arkansas, CAST

       Postgres modifications: Janne Soimasuo, Faculty of Forestry, University
       of Joensuu, Finland.

       Updated to GRASS 5 by Alex Shevlakov (sixote@yahoo.com)



GRASS 5.0							 g.stats.pg(1)
