[SciPy-user] Inconsistencies between numpy & scipy corrcoef

Steve Lianoglou lists.steve@arachnedesign....
Mon Oct 15 16:51:27 CDT 2007

>> Just curious if there's any reason why
>> scipy.stats.corrcoeff and numpy.corrcoef (andy by
>> extension the `cov` functions) act differently, e.g if you
>> are passing both of them a 2d array, scipy will take the
>> rows to be the observations and the cols are the vars,
>> numpy is the opposite.
> It is actually worse than this:
> scipy.corrcoef is just numpy.corrcoef,
> but scipy.stats.corrcoef is as you say,
> so SciPy itself contains two conflicting versions.
> I agree that this shd match numpy.
> The stats version may need to be deprecated
> or to force an axis argument.

So why not have the scipy methods just call down back the numpy  
methods (or do some import magic in the scipy.stats module to just  
import the numpy funcs into the namespace)?

Since you need numpy before installing scipy, why have duplicate code?


More information about the SciPy-user mailing list