MATLAB Answers

In which Matlab version was rng() introduced?

4 views (last 30 days)
Johannes Pfeifer
Johannes Pfeifer on 31 Jan 2020
Answered: Adam on 31 Jan 2020
The old syntax to set the seed of a random number generator like
randn('state',1)
is discouraged. Instead, it is recommended to use
rng(1);
However, as far as I know, older versions of Matlab did not yet have that functionality. But in contrast to other functions, the documentation https://mathworks.com/help/matlab/ref/rng.html does not mention in which version the current functionality was introduced.

  0 Comments

Sign in to comment.

More Answers (0)

Sign in to answer this question.