A pseudo random utility namespace. When non deterministic functions are used to produce a score, it is valuable to be able to capture the seed of randomnes in order to reproduce at a later point.
A pseudo random utility namespace. When non deterministic functions are used to produce a score, it is valuable to be able to capture the seed of randomnes in order to reproduce at a later point.
(rand)
(rand max)
Generate a float between 0 and 1 based on random*
Generate a float between 0 and 1 based on random*
(rand-between min max)
Generate a float between min and max based on random*
Generate a float between min and max based on random*
(rand-int max)
(rand-int-between)
(rand-int-between lo hi)
Uniform distribution from lo (inclusive) to hi (exclusive). Defaults to range of Java long.
Uniform distribution from lo (inclusive) to hi (exclusive). Defaults to range of Java long.
(rand-nth xs)
(with-rand s & exprs)
cljdoc builds & hosts documentation for Clojure/Script libraries
Ctrl+k | Jump to recent docs |
← | Move to previous article |
→ | Move to next article |
Ctrl+/ | Jump to the search field |