[Numpy-discussion] Cross-covariance function
Thu Jan 26 10:25:38 CST 2012
Le 26/01/2012 16:50, Pauli Virtanen a écrit :
> the current behavior is not a bug,
I completely agree that numpy.cov(m,y) does what it says !
I (and apparently some other people) are only questioning why there is
such a behavior ? Indeed, the second variable `y` is presented as "An
additional set of variables and observations".
This raises for me two different questions :
* What is the use case for such an additional set of variables that
could just be concatenated to the first set `̀m` ?
* Or, if indeed this sort of integrated concatenation is useful, why
just add one "additional set" and not several "additional sets" like :
>>> cov(m, y1, y2, y3, ....) ?
But I would understand that numpy responsibility to provide a stable
computing API would prevent any change in cov behavior. You have the
long term experience to judge that. (I certainly don't ;-) )
However, in the case this change is not possible, I would see this
* add and xcov function that does what Elliot and Sturla and I
* possibly deprecate the `y` 2nd argument of cov because I feel it
brings more definition complication than real programming benefits
(but I still find that changing cov would lead to a leaner numpy API
which was my motivation for reacting to Elliot's first message)
More information about the NumPy-Discussion