Skip to content

cluseed

Initialize the random number generator with a given seed.

 cluseed(seed)

Arguments

  • seed: Seed for initializing the random number generator.

Note

This function works in both MATLAB or Octave and simplifies reproducible executions of the different stochastic functions in this package. Note that reproducibility is only guaranteed within the same version of either MATLAB or Octave.

Examples

% Set seed to 123
cluseed(123);