X-Git-Url: http://git.onelab.eu/?p=myops.git;a=blobdiff_plain;f=web%2Fcollect%2Fserver%2Fstats.py;fp=web%2Fcollect%2Fserver%2Fstats.py;h=8afd03afd8adc90eedbb7554865512b814afeb3a;hp=0000000000000000000000000000000000000000;hb=85070b3d456667f238051af1a2f1f2a0c12300ab;hpb=607f0e13927eb18075c375fa9ba5527da4fcbb44 diff --git a/web/collect/server/stats.py b/web/collect/server/stats.py new file mode 100755 index 0000000..8afd03a --- /dev/null +++ b/web/collect/server/stats.py @@ -0,0 +1,21 @@ +#!/usr/bin/python + +import sys + +def getListFromFile(f): + list = [] + for line in f: + line = line.strip() + list += [line] + return list + +l = getListFromFile(sys.stdin) +l = [ float(x) for x in l ] +# mean and standard deviation +ls = len(l) +print "05th", l[int(ls*0.05)] +print "25th", l[int(ls*0.25)] +print "50th", l[int(ls*0.50)] +print "75th", l[int(ls*0.75)] +print "95th", l[int(ls*0.95)] +