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

Method test_random

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

Source from the content-addressed store, hash-verified

1906 assert_array_equal(digitize(x, bins), np.arange(11))
1907
1908 def test_random(self):
1909 x = rand(10)
1910 bin = np.linspace(x.min(), x.max(), 10)
1911 assert_(np.all(digitize(x, bin) != 0))
1912
1913 def test_right_basic(self):
1914 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