[Numpy-discussion] How to Extract the Number of Rows and Columns in a Matrix
Mon Mar 26 18:26:38 CDT 2012
len(M) will give you the number of rows of M.
For columns I just use M.shape myself, I don't know if there exists a
Le 26 mars 2012 19:03, Stephanie Cooke <firstname.lastname@example.org> a écrit :
> I would like to extract the number of rows and columns of a matrix
> individually. The shape command outputs the rows and columns together,
> but are there commands that will separately give the rows and
> separately give the columns?
> NumPy-Discussion mailing list
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the NumPy-Discussion