[Numpy-discussion] matrix.std() returns array

Travis Oliphant oliphant.travis at ieee.org
Thu Apr 27 00:53:00 CDT 2006


Keith Goodman wrote:
> I noticed that the mean of a matrix is a matrix but the standard
> deviation of a matrix is an array. Is that the expected behavior? I'm
> also getting the wrong values (0 and nan) for the standard deviation.
> Did I mess something up?
>
> I'm trying to learn scipy (and python) by porting a small Octave
> program. I installed numpy from svn (today) on a Debian box. And
> numpy.test() says OK.
>
>   
This should be fixed now in SVN.  If somebody can add a test that would 
be great.

Note, that the methods taking axes also now preserve row and column 
orientation for matrices.

-Travis





More information about the Numpy-discussion mailing list