MCPcopy Create free account
hub / github.com/numpy/numpy / test_min

Method test_min

numpy/matrixlib/tests/test_defmatrix.py:102–110  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

100 assert_equal(np.max(x, axis=1), matrix([[3], [6]]))
101
102 def test_min(self):
103 x = matrix([[1, 2, 3], [4, 5, 6]])
104 assert_equal(x.min(), 1)
105 assert_equal(x.min(0), matrix([[1, 2, 3]]))
106 assert_equal(x.min(1), matrix([[1], [4]]))
107
108 assert_equal(np.min(x), 1)
109 assert_equal(np.min(x, axis=0), matrix([[1, 2, 3]]))
110 assert_equal(np.min(x, axis=1), matrix([[1], [4]]))
111
112 def test_ptp(self):
113 x = np.arange(4).reshape((2, 2))

Callers

nothing calls this directly

Calls 3

matrixClass · 0.90
assert_equalFunction · 0.90
minMethod · 0.45

Tested by

no test coverage detected