Select a random element in an array with a custom distribution.
an array of elements
function returning the relative probability of each element
an element or undefined if array is empty
Generated using TypeDoc
Select a random element in an array with a custom distribution.