[Scipy-tickets] [SciPy] #518: scipy.stats skew and kurtosis return different types

SciPy scipy-tickets@scipy....
Mon Oct 22 13:47:50 CDT 2007


#518: scipy.stats skew and kurtosis return different types
---------------------+------------------------------------------------------
 Reporter:  jdh2358  |       Owner:  somebody
     Type:  defect   |      Status:  new     
 Priority:  normal   |   Milestone:  0.7     
Component:  Other    |     Version:          
 Severity:  normal   |    Keywords:          
---------------------+------------------------------------------------------
 The following scrip illustrates the different return types

 import numpy; print numpy.__version__
 import scipy; print scipy.__version__
 import scipy.stats

 a = numpy.arange(100)
 sa = scipy.stats.skew(a)
 ka = scipy.stats.kurtosis(a)
 print "skew return val=%s, type=%s" % (sa, type(sa))
 print "kurtosis val=%s, return type=%s" % (ka, type(ka))


 with output:
 johnh@flag:~> python test.py
 1.0.4.dev4154
 0.7.0.dev3456
 skew return val=0.0, type=<type 'numpy.ndarray'>
 kurtosis val=-1.200240024, return type=<type 'numpy.float64'>

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


More information about the Scipy-tickets mailing list