(self)
| 2451 | np.seterr(**self.err_status) |
| 2452 | |
| 2453 | def test_testUfuncRegression(self): |
| 2454 | # Tests new ufuncs on MaskedArrays. |
| 2455 | for f in ['sqrt', 'log', 'log10', 'exp', 'conjugate', |
| 2456 | 'sin', 'cos', 'tan', |
| 2457 | 'arcsin', 'arccos', 'arctan', |
| 2458 | 'sinh', 'cosh', 'tanh', |
| 2459 | 'arcsinh', |
| 2460 | 'arccosh', |
| 2461 | 'arctanh', |
| 2462 | 'absolute', 'fabs', 'negative', |
| 2463 | 'floor', 'ceil', |
| 2464 | 'logical_not', |
| 2465 | 'add', 'subtract', 'multiply', |
| 2466 | 'divide', 'true_divide', 'floor_divide', |
| 2467 | 'remainder', 'fmod', 'hypot', 'arctan2', |
| 2468 | 'equal', 'not_equal', 'less_equal', 'greater_equal', |
| 2469 | 'less', 'greater', |
| 2470 | 'logical_and', 'logical_or', 'logical_xor', |
| 2471 | ]: |
| 2472 | try: |
| 2473 | uf = getattr(umath, f) |
| 2474 | except AttributeError: |
| 2475 | uf = getattr(fromnumeric, f) |
| 2476 | mf = getattr(numpy.ma.core, f) |
| 2477 | args = self.d[:uf.nin] |
| 2478 | ur = uf(*args) |
| 2479 | mr = mf(*args) |
| 2480 | assert_equal(ur.filled(0), mr.filled(0), f) |
| 2481 | assert_mask_equal(ur.mask, mr.mask, err_msg=f) |
| 2482 | |
| 2483 | def test_reduce(self): |
| 2484 | # Tests reduce on MaskedArrays. |
nothing calls this directly
no test coverage detected