MCPcopy
hub / github.com/numpy/numpy / test_random

Method test_random

numpy/lib/tests/test_function_base.py:2165–2168  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

2163 assert_array_equal(digitize(x, bins), np.arange(11))
2164
2165 def test_random(self):
2166 x = rand(10)
2167 bin = np.linspace(x.min(), x.max(), 10)
2168 assert_(np.all(digitize(x, bin) != 0))
2169
2170 def test_right_basic(self):
2171 x = [1, 5, 4, 10, 8, 11, 0]

Callers

nothing calls this directly

Calls 7

assert_Function · 0.90
digitizeFunction · 0.90
randFunction · 0.85
linspaceMethod · 0.80
minMethod · 0.45
maxMethod · 0.45
allMethod · 0.45

Tested by

no test coverage detected