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

SciPy scipy-tickets@scipy....
Sun Oct 26 12:17:27 CDT 2008

#518: scipy.stats skew and kurtosis return different types
 Reporter:  jdh2358      |        Owner:  somebody
     Type:  defect       |       Status:  new     
 Priority:  normal       |    Milestone:  0.7.0   
Component:  scipy.stats  |      Version:          
 Severity:  normal       |   Resolution:          
 Keywords:               |  
Comment (by wesm):

 One problem here is that scipy.stats.skew returns a 0-dim ndarray for a
 1-d vector

 In [25]: from scipy.stats import skew

 In [26]: skew(arange(100))
 Out[26]: array(0.0)

 This has the potential to break a lot of things, particularly anything
 expecting a value instead of a degenerate array :). I am not sure of the
 appropriate fix but both skew and kurtosis (and any other scipy.stats
 functions) should not be able to return a 0-dim array.

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

More information about the Scipy-tickets mailing list