math statistics

Pushes on the stack a function which emits values according to a provided value histogram.

The randomization is seeded. The seeded PRNG must have been initialized beforehand using PRNG.

The result is a function. This function does not have any arguments.

To use the function pushed by SRANDPDF onto the stack, use EVAL.

SRANDPDF is available since version 2.2.1.

See also



42 PRNG { 0 2 1 1 2 1 } SRANDPDF 'p' STORE $p EVAL $p EVAL $p EVAL $p EVAL