MCPcopy
hub / github.com/numpy/numpy / _create_data

Method _create_data

numpy/ma/tests/test_old_ma.py:100–113  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

98class TestMa:
99
100 def _create_data(self):
101 x = np.array([1., 1., 1., -2., pi / 2.0, 4., 5., -10., 10., 1., 2., 3.])
102 y = np.array([5., 0., 3., 2., -1., -4., 0., -10., 10., 1., 0., 3.])
103 a10 = 10.
104 m1 = [1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0]
105 m2 = [0, 0, 1, 0, 0, 1, 1, 0, 0, 0, 0, 1]
106 xm = array(x, mask=m1)
107 ym = array(y, mask=m2)
108 z = np.array([-.5, 0., .5, .8])
109 zm = array(z, mask=[0, 1, 0, 0])
110 xf = np.where(m1, 1e+20, x)
111 s = x.shape
112 xm.set_fill_value(1e+20)
113 return x, y, a10, m1, m2, xm, ym, z, zm, xf, s
114
115 def test_testBasic1d(self):
116 # Test of basic array creation and properties in 1 dimension.

Callers 7

test_testBasic1dMethod · 0.95
test_testBasic2dMethod · 0.95
test_testArithmeticMethod · 0.95
test_testUfuncs1Method · 0.95
test_testMinMaxMethod · 0.95
test_testAddSumProdMethod · 0.95
test_testMaPutMethod · 0.95

Calls 1

arrayFunction · 0.90

Tested by

no test coverage detected