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

Method test_var

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

Source from the content-addressed store, hash-verified

121 assert_(np.all(mx.ptp(1) == np.array([1, 1])))
122
123 def test_var(self):
124 x = np.arange(9).reshape((3, 3))
125 mx = x.view(np.matrix)
126 assert_equal(x.var(ddof=0), mx.var(ddof=0))
127 assert_equal(x.var(ddof=1), mx.var(ddof=1))
128
129 def test_basic(self):
130 import numpy.linalg as linalg

Callers

nothing calls this directly

Calls 4

assert_equalFunction · 0.90
reshapeMethod · 0.80
viewMethod · 0.45
varMethod · 0.45

Tested by

no test coverage detected