Re: [Numpy-discussion] problem on testing numpy

2007-08-26 Thread Stefan van der Walt
On Fri, Aug 24, 2007 at 05:46:55PM +0200, Vivian Tini wrote: Dear All, I have just installed NumPy and I am excited to test it. Since I have no access as root then I installed Numpy in my home directory. The following messages appears as I tried some commands: import numpy Running

[Numpy-discussion] numpy.random.multinomial() cannot handle zero's

2007-08-26 Thread Michael Nandris
Hi, Is there an easy way around this problem, that does not involve fixing the API (like using NaN instead of 0.0)? from numpy.random import multinomial multinomial(100,[ 0.2, 0.4, 0.1, 0.3 ]) array([19, 45, 10, 26]) multinomial( 100, [0.2, 0.0, 0.8, 0.0] ) Traceback (most recent call last):