Categories: None [Edit]

discrete_distribution

https://rubygems.org/gems/discrete_distribution
https://github.com/scooter-dangle/discrete_distribution
Fork of aliastable by Paul J Sanchez. If a categorical distribution has k distinct values, traditional approaches will require O(k) work to pick an outcome with the correct probabilities. This algorithm uses conditional probability to construct a table which will yield outcomes with the correct probabilities, but in O(1) time.

Total

Ranking: 140,603 of 190,443
Downloads: 4,299

Daily

Ranking: 96,776 of 190,400
Downloads: 0

Depended by

RankDownloadsName

Depends on

RankDownloadsName
13,250,662,047bundler
81,258,433,457rake
141,166,723,091minitest
72584,452,558pry
1,10841,552,502pry-doc

Owners

#GravatarHandle
1iconscottlsteele