diff options
author | Travis Oliphant <oliphant@enthought.com> | 2006-07-07 18:55:19 +0000 |
---|---|---|
committer | Travis Oliphant <oliphant@enthought.com> | 2006-07-07 18:55:19 +0000 |
commit | d896e9ee78d865474ab85c64a648c05834225966 (patch) | |
tree | de6feb80ca57fb10d63bd787bac14ebee7d2ed12 /numpy/core/ma.py | |
parent | 5ee14815b3520074e73b2b2836a8a11de0cc9fc2 (diff) | |
download | numpy-d896e9ee78d865474ab85c64a648c05834225966.tar.gz |
Make .T == .transpose()
Diffstat (limited to 'numpy/core/ma.py')
-rw-r--r-- | numpy/core/ma.py | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/numpy/core/ma.py b/numpy/core/ma.py index 6231ed5c7..102fecf78 100644 --- a/numpy/core/ma.py +++ b/numpy/core/ma.py @@ -1392,12 +1392,8 @@ array(data = %(data)s, return self._data.ctypes def _get_T(self): - if (self.ndim == 0): + if (self.ndim < 2): return self - if (self.ndim == 1): - ret = self.view() - ret.shape = (self.shape[0], 1) - return ret return self.transpose() shape = property(_get_shape, _set_shape, |