bundles / numpy latest / numpy / random / RandomState / rand
cython_function_or_method
numpy.random:RandomState.rand
Summary
Random values in a given shape.
Extended Summary
Create an array of the given shape and populate it with random samples from a uniform distribution over [0, 1).
Parameters
d0, d1, ..., dn: int, optionalThe dimensions of the returned array, must be non-negative. If no argument is given a single Python float is returned.
Returns
out: ndarray, shape ``(d0, d1, ..., dn)``Random values.
Examples
np.random.rand(3,2)
✗See also
Aliases
-
numpy.random.rand -
numpy.random.RandomState.rand