Skip to content

randi

builtin · libnexusinterp/corefcn/rand-proprietary.cc

: R = randi (imax)
: R = randi ([imin imax], n, …)
: R = randi (…, class)

Uniformly distributed pseudorandom integers.

Values are drawn from 1:imax or imin:imax using the generator of rand. Size arguments are as for rand; class may be "double", "single" or an integer class name, with values limited to the range of the class.