This is a pre-release version (latest).Go to latest (1.18.0)
{ } Raw JSON

bundles / scipy latest / scipy / stats / _qmc / check_random_state

function

scipy.stats._qmc:check_random_state

source: build-install/usr/lib/python3.14/site-packages/scipy/stats/_qmc.py:58

Signature

def check_random_state(seed = None)

Summary

Turn seed into a numpy.random.Generator instance.

Parameters

seed : {None, int, `numpy.random.Generator`, `numpy.random.RandomState`}, optional

If seed is an int or None, a new numpy.random.Generator is created using np.random.default_rng(seed). If seed is already a Generator or RandomState instance, then the provided instance is used.

Returns

seed : {`numpy.random.Generator`, `numpy.random.RandomState`}

Random number generator.

Aliases

  • scipy.stats._multicomp.check_random_state