diff options
| author | jamestwebber <jamestwebber@gmail.com> | 2013-04-20 11:50:11 -0700 |
|---|---|---|
| committer | jamestwebber <jamestwebber@gmail.com> | 2013-04-20 11:50:11 -0700 |
| commit | 4e6b48e65ed839ab57eb66e38f9b08f3f43163be (patch) | |
| tree | 6050a65e3b46e46794d1020e30a308b2eeb818bf /numpy | |
| parent | 1975606394d577421c4b4e21abb8fdadbdc572c0 (diff) | |
| download | numpy-4e6b48e65ed839ab57eb66e38f9b08f3f43163be.tar.gz | |
Update masked array copy to preserve array order
Using 'K' to try to match array order, fixes https://github.com/numpy/numpy/issues/3156
Diffstat (limited to 'numpy')
| -rw-r--r-- | numpy/ma/core.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/numpy/ma/core.py b/numpy/ma/core.py index e1e848206..38076e8b3 100644 --- a/numpy/ma/core.py +++ b/numpy/ma/core.py @@ -3438,12 +3438,12 @@ class MaskedArray(ndarray): return np.asanyarray(fill_value) # if m.dtype.names: - result = self._data.copy() + result = self._data.copy('K') _recursive_filled(result, self._mask, fill_value) elif not m.any(): return self._data else: - result = self._data.copy() + result = self._data.copy('K') try: np.copyto(result, fill_value, where=m) except (TypeError, AttributeError): |
