[Numpy-discussion] scipy.stats.poisson.ppf raises "OverflowError: cannot convert float infinity to long"

Maria Liukis liukis@usc....
Tue Aug 4 18:03:44 CDT 2009


Josef,

Thanks a bunch!
Masha
--------------------
liukis@usc.edu



On Aug 4, 2009, at 4:01 PM, josef.pktd@gmail.com wrote:

> On Tue, Aug 4, 2009 at 6:36 PM, Maria Liukis<liukis@usc.edu> wrote:
>> Hello everybody,
>> I'm using the following versions of scipy and numpy:
>>>>> scipy.__version__
>> '0.6.0'
>>>>> import numpy
>>>>> numpy.__version__
>> '1.1.1'
>> Would anybody happen to know why I get an exception when calling
>> scipy.stats.poisson.ppf function:
>>>>> from scipy.stats import *
>>>>> poisson.ppf(0.9999, 4)
>> Traceback (most recent call last):
>>   File "<stdin>", line 1, in <module>
>>   File "/usr/lib64/python2.5/site-packages/scipy/stats/ 
>> distributions.py",
>> line 3601, in ppf
>>     place(output,cond2,self.b)
>>   File "/usr/lib64/python2.5/site-packages/numpy/lib/ 
>> function_base.py", line
>> 957, in place
>>     return _insert(arr, mask, vals)
>> OverflowError: cannot convert float infinity to long
>
>>>> stats.poisson.ppf(0.9999, 4)
> 13.0
>>>> stats.poisson.cdf(13, 4)
> 0.99992367158465667
>
> should be fixed since scipy 0.7.0
>
> Josef
>
>>>>>
>> Thanks a lot in advance,
>> Masha
>> --------------------
>> liukis@usc.edu
>>
>>
>>
>> _______________________________________________
>> NumPy-Discussion mailing list
>> NumPy-Discussion@scipy.org
>> http://mail.scipy.org/mailman/listinfo/numpy-discussion
>>
>>
> _______________________________________________
> NumPy-Discussion mailing list
> NumPy-Discussion@scipy.org
> http://mail.scipy.org/mailman/listinfo/numpy-discussion

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.scipy.org/pipermail/numpy-discussion/attachments/20090804/fb503f3d/attachment-0001.html 


More information about the NumPy-Discussion mailing list