MCPcopy Index your code
hub / github.com/numpy/numpy / test_asmatrix

Method test_asmatrix

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

Source from the content-addressed store, hash-verified

175 assert_(np.all(abs(mB > 0)))
176
177 def test_asmatrix(self):
178 A = np.arange(100).reshape(10, 10)
179 mA = asmatrix(A)
180 A[0, 0] = -10
181 assert_(A[0, 0] == mA[0, 0])
182
183 def test_noaxis(self):
184 A = matrix([[1, 0], [0, 1]])

Callers

nothing calls this directly

Calls 3

asmatrixFunction · 0.90
assert_Function · 0.90
reshapeMethod · 0.80

Tested by

no test coverage detected