mappings should rather be called "sumabs" and "avgabs" than "abssum" and "absavg"

This commit is contained in:
Christoph Kords 2011-07-15 11:27:47 +00:00
parent 63451f6edf
commit cb96559d99
1 changed files with 3 additions and 3 deletions

View File

@ -400,9 +400,9 @@ def mapIncremental(label, mapping, N, base, new):
theMap = { 'min': lambda n,b,a: min(b,a), theMap = { 'min': lambda n,b,a: min(b,a),
'max': lambda n,b,a: max(b,a), 'max': lambda n,b,a: max(b,a),
'avg': lambda n,b,a: (n*b+a)/(n+1), 'avg': lambda n,b,a: (n*b+a)/(n+1),
'absavg': lambda n,b,a: (n*b+abs(a))/(n+1), 'avgabs': lambda n,b,a: (n*b+abs(a))/(n+1),
'sum': lambda n,b,a: b+a, 'sum': lambda n,b,a: b+a,
'abssum': lambda n,b,a: b+abs(a), 'sumabs': lambda n,b,a: b+abs(a),
'unique': lambda n,b,a: {True:a,False:'n/a'}[n==0 or b==a] 'unique': lambda n,b,a: {True:a,False:'n/a'}[n==0 or b==a]
} }
if mapping in theMap: if mapping in theMap:
@ -625,7 +625,7 @@ parser.add_option('-r','--range', dest='range', type='int', nargs=3, \
parser.add_option('--sloppy', action='store_true', dest='sloppy', \ parser.add_option('--sloppy', action='store_true', dest='sloppy', \
help='do not pre-check validity of increment range') help='do not pre-check validity of increment range')
parser.add_option('-m','--map', dest='func', type='string', \ parser.add_option('-m','--map', dest='func', type='string', \
help='data reduction mapping ["%default"] out of min, max, avg, absavg, sum, abssum or user-lambda') help='data reduction mapping ["%default"] out of min, max, avg, avgabs, sum, sumabs or user-lambda')
parser.add_option('-p','--type', dest='filetype', type='string', \ parser.add_option('-p','--type', dest='filetype', type='string', \
help = 'type of result file [%default]') help = 'type of result file [%default]')