poissonsamples

A small module to get samples from lambda distribution

Usage no npm install needed!

<script type="module">
  import poissonsamples from 'https://cdn.skypack.dev/poissonsamples';
</script>

README

A small library to return a sample from the lambda distribution.

Usage:

const poissonSample = require("poissonsamples");

console.log(poissonSample.getSample(1000));

It uses jStat library for lambda less than 10, and for more than 10, it uses Rejection method, described in this paper. There is no limit on how big or small lambda can be.