scipy.stats.rv_discrete.

scipy.stats.rv_discrete.random_state#

property rv_discrete.random_state#

取得或設定用於產生隨機變數的產生器物件。

如果 random_state 為 None (或 np.random),則使用 numpy.random.RandomState 單例。如果 random_state 為整數,則會使用新的 RandomState 實例,並以 random_state 作為種子。如果 random_state 已經是 GeneratorRandomState 實例,則會使用該實例。