numpy.ma.MaskedArray.T#

property

property ma.MaskedArray.T#

转置数组的视图.

self.transpose() 相同.

参见

transpose

示例

>>> import numpy as np
>>> a = np.array([[1, 2], [3, 4]])
>>> a
array([[1, 2],
       [3, 4]])
>>> a.T
array([[1, 3],
       [2, 4]])
>>> a = np.array([1, 2, 3, 4])
>>> a
array([1, 2, 3, 4])
>>> a.T
array([1, 2, 3, 4])