summaryrefslogtreecommitdiff
path: root/numpy/ma/tests/test_extras.py
diff options
context:
space:
mode:
authormattip <matti.picus@gmail.com>2022-07-20 09:28:42 +0300
committermattip <matti.picus@gmail.com>2022-07-20 09:28:42 +0300
commit20bd00b0bfef5de4046d31a04b84f0a5a4007cdf (patch)
tree7b7ef991c2a8c7f493e14d6ea05f3336a255429c /numpy/ma/tests/test_extras.py
parent3321bc59ca5e47a8d8677fa4d1a9af37d570a835 (diff)
downloadnumpy-20bd00b0bfef5de4046d31a04b84f0a5a4007cdf.tar.gz
Revert "BUG: Fix masked median multiple masked arrays (#21999)"
This reverts commit 6b8d55e66e532d66e1701ad039b4cda306839b3f.
Diffstat (limited to 'numpy/ma/tests/test_extras.py')
-rw-r--r--numpy/ma/tests/test_extras.py19
1 files changed, 0 insertions, 19 deletions
diff --git a/numpy/ma/tests/test_extras.py b/numpy/ma/tests/test_extras.py
index 3637accc3..04bf8cfc2 100644
--- a/numpy/ma/tests/test_extras.py
+++ b/numpy/ma/tests/test_extras.py
@@ -1160,25 +1160,6 @@ class TestMedian:
o[2] = np.nan
assert_(type(np.ma.median(o.astype(object))), float)
- def test_list_of_masked_array(self):
- data1 = np.array([[1, 2, 3, 4], [5, 6, 7, 8]])
- masked1 = np.ma.masked_where(data1 == 4, data1)
- data2 = np.array([[8, 7, 6, 5], [4, 3, 2, 1]])
- masked2 = np.ma.masked_where(data2 == 4, data2)
- list = [masked1, masked2]
- median_masked_list = np.ma.median(list, axis=0).data
- assert_equal(median_masked_list,
- np.array([[4.5, 4.5, 4.5, 5], [5, 4.5, 4.5, 4.5]]))
-
- def test_list_of_masked_array_no_axis(self):
- data1 = np.array([[1, 2, 3, 4], [5, 6, 7, 8]])
- masked1 = np.ma.masked_where(data1 == 2, data1)
- data2 = np.array([[8, 7, 6, 5], [4, 3, 2, 1]])
- masked2 = np.ma.masked_where(data2 == 5, data2)
- list = [masked1, masked2]
- median_masked_list = np.ma.median(list)
- assert_equal(median_masked_list, 4.5)
-
class TestCov: