Fast Sampling From A Discrete Distribution

This function generates independent random samples according to a prescribed discrete distribution.

Download
Download

You are now following this Submission

Cite As

Peng Liu (2026). Fast Sampling From A Discrete Distribution (https://ch.mathworks.com/matlabcentral/fileexchange/59724-fast-sampling-from-a-discrete-distribution), MATLAB Central File Exchange. Retrieved .

Acknowledgements

Inspired by: Sampling from a discrete distribution

Categories

Find more on Random Number Generation in Help Center and MATLAB Answers

General Information

MATLAB Release Compatibility

  • Compatible with any release

Platform Compatibility

  • Windows
  • macOS
  • Linux
Version Published Release Notes Action
1.0.0

more accurate title

Download