What steps will reproduce the problem?
from statlib import stats
stats.median([1,2,3,3,3])
What is the expected output? What do you see instead?
I expect "3", but get this exception:
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/usr/local/lib/python2.6/dist-packages/statlib-1.1-py2.6.egg/statlib/stats.py", line 288, in __call__
return apply(self._dispatch[type(arg1)], (arg1,) + args, kw)
File "/usr/local/lib/python2.6/dist-packages/statlib-1.1-py2.6.egg/statlib/stats.py", line 355, in lmedian
LRL = smallest + binsize*cfbin # get lower read limit of that bin
UnboundLocalError: local variable 'cfbin' referenced before assignment
What version of the product are you using? On what operating system?
version 1.1 on Ubuntu 10.10
Please provide any additional information below.
It seems to fail whenever the median value is also the largest?
Original issue reported on code.google.com by thejohnn...@gmail.com on 12 Jan 2011 at 7:26
Original issue reported on code.google.com by
thejohnn...@gmail.com
on 12 Jan 2011 at 7:26