Doing Averages

From Geoqo
(Difference between revisions)
Jump to: navigation, search
 
(One intermediate revision by one user not shown)
Line 5: Line 5:
 
Lets say you want to show averages for terrain, difficulty, or whatever else might be numeric in the text (class of service for geodining data, for example):
 
Lets say you want to show averages for terrain, difficulty, or whatever else might be numeric in the text (class of service for geodining data, for example):
  
Create a script (put it in, say, $HOME/.geoqo/scripts/average):
+
Create a script (put it in, say, $[[HOME]]/.geoqo/scripts/average):
  
 
   %search
 
   %search
Line 41: Line 41:
 
  Ave Difficulty: 1.90278
 
  Ave Difficulty: 1.90278
 
     Ave Terrain: 1.36111
 
     Ave Terrain: 1.36111
 +
 +
{{TRICKS}}

Latest revision as of 21:38, 2 April 2007

(you should probably read Scripting Examples for Mulitple Top10 Outputs first)

requires geoqo 0.7 which isn't out at the time of this writing

Lets say you want to show averages for terrain, difficulty, or whatever else might be numeric in the text (class of service for geodining data, for example):

Create a script (put it in, say, $HOME/.geoqo/scripts/average):

 %search
 cache:owner_name==%[Owner]

 %print
 ======================================================================
 %print
 STATS FOR CACHES MADE BY %[Owner]

 %display
 top10:groundspeak_container

 # the show=0 here will display *only* the average
 %display
 top10:groundspeak_difficulty,doaverage=1,show=0,averagetext=Ave Difficulty:

 %display
 top10:groundspeak_terrain,doaverage=1,show=0,averagetext=   Ave Terrain:

Will result as follows when run:

> geoqo -x averages:Owner=Yamar

======================================================================
STATS FOR CACHES MADE BY Yamar
Top 10 'groundspeak_container's
 Num    % Value
----------------------------------------------------------------------
  17   47 Micro
  13   36 Regular
   4   11 Small
   1    2 Not chosen
   1    2 Other
Ave Difficulty: 1.90278
   Ave Terrain: 1.36111

Tips and Tricks

Personal tools