[Scipy-tickets] [SciPy] #583: negative binomial fails with 0 < r < 1

SciPy scipy-tickets@scipy....
Fri Jan 11 16:31:27 CST 2008

#583: negative binomial fails with 0 < r < 1
 Reporter:  danhs        |       Owner:  somebody                 
     Type:  defect       |      Status:  new                      
 Priority:  normal       |   Milestone:                           
Component:  scipy.stats  |     Version:  none                     
 Severity:  normal       |    Keywords:  nbinom, negative binomial
 With r < 1 it seems that the negative binomial function has some
 noteworthy failures.


 nbinom = scipy.stats.nbinom(0.88, 0.42)

 # These will have errors:

 # Strangely this does not:

 My purpose was to create a random sample from the negative binomial so, I
 was able to use the following code successfully:


 Negative binomial is defined for r greater than 0 (real numbers), and for
 p in range 0 to 1 according to wikipedia

 So these should be acceptable inputs.

 This was observed on scipy 0.6.0.

Ticket URL: <http://www.scipy.org/scipy/scipy/ticket/583>
SciPy <http://www.scipy.org/>
SciPy is open-source software for mathematics, science, and engineering.

More information about the Scipy-tickets mailing list