cauchy(median?, spread?)
number → numberA heavy-tailed draw around median (default 0) with the given spread (default 1).
Chance: drawn once as the program is lowered, or running as a signal.
A heavy-tailed draw around median (default 0) with the given spread (default 1).
count elements chosen. Does not repeat.
Asking for the whole list is equivalent to scramble.
len is an error.
1 or 0, coin() is even 50/50 probability.
coin(0.25) is 1 one time in four.
An exponentially distributed number above zero with the given mean (default 1).
A normally distributed number: clustered around mean,
two thirds of it within one deviation.
Both default to the standard 0 and 1.
Unbounded.
Nudge a number off its grid: x plus random amount.
A power-law draw at or above scale (default 1).
A smaller shape (default 1) makes big values likelier.
A whole count averaging mean (default 1).
A uniform number.
rand() draws from 0..1; rand(lo, hi) — or 60.rand(72) — draws from lo..hi,
with hi excluded.
A uniform whole number in lo..hi,
with hi excluded. Both bounds must be whole.
A list of count whole numbers in lo..hi, hi excluded.
A list of count uniform numbers, from 0..1 or from lo..hi.
count notes drawn evenly from the tones of a scale given as semitone offsets within an octave between MIDI lo and hi (60..72 by default).
Unlike snapping a uniform draw with scale,
every degree is equally likely and nothing lands outside the range: randscale(8, [0, 3, 5, 7, 10], 48, 72) is a pentatonic riff over two octaves.
Use a fixed seed for all random values after it is set.
A voice is lowered per note and does not see a top-level seed,
so a seed inside an instrument pins that instrument identically on every note.
A triangular draw over lo..hi,
peaking at mode.
A random walk. Count numbers beginning at start,
each drifting from the one before by up to step either way.
walk in whole steps: each move is a whole number from -step to step,
so the result stays on the semitone grid.
walki(16, 60, 2) wanders a melody around middle C.
step must be whole.
17names in Random. All categories.