[Scipy-tickets] [SciPy] #539: inconsistent behavior of scipy.stats.distributions.randint

SciPy scipy-tickets@scipy....
Thu Nov 15 19:36:14 CST 2007


#539: inconsistent behavior of scipy.stats.distributions.randint
-------------------------+--------------------------------------------------
 Reporter:  emv          |       Owner:  somebody
     Type:  defect       |      Status:  new     
 Priority:  low          |   Milestone:  0.7     
Component:  scipy.stats  |     Version:          
 Severity:  minor        |    Keywords:          
-------------------------+--------------------------------------------------
 from scipy.stats.distributions import *

 In [21]: distribution = randint(32, 1024)

 In [22]: rv = distribution.rvs()

 In [23]: print rv.__class__
 <type 'numpy.int64'>

 wheras for every other distribution, an array is returned.

 In [28]: distribution = poisson(32)

 In [29]: rv = distribution.rvs()

 In [30]: print rv.__class__
 <type 'numpy.ndarray'>

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


More information about the Scipy-tickets mailing list