[Scipy-tickets] [SciPy] #771: scipy.stats.skew returns a 0-dim ndarray for a 1-d vector

SciPy scipy-tickets@scipy....
Sat Nov 1 05:29:34 CDT 2008


#771: scipy.stats.skew returns a 0-dim ndarray for a 1-d vector
--------------------------+-------------------------------------------------
 Reporter:  parautenbach  |       Owner:  somebody
     Type:  defect        |      Status:  new     
 Priority:  normal        |   Milestone:  0.7.0   
Component:  scipy.stats   |     Version:  devel   
 Severity:  normal        |    Keywords:          
--------------------------+-------------------------------------------------
 10/26/08 12:17:26 changed 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/771>
SciPy <http://www.scipy.org/>
SciPy is open-source software for mathematics, science, and engineering.


More information about the Scipy-tickets mailing list