DiscreteSampler
public class SmallMeanPoissonSampler extends java.lang.Object implements DiscreteSampler
mean < 40
.
For large means, LargeMeanPoissonSampler
should be used instead.Constructor | Description |
---|---|
SmallMeanPoissonSampler(org.apache.commons.rng.UniformRandomProvider rng,
double mean) |
Modifier and Type | Method | Description |
---|---|---|
int |
sample() |
Creates a sample.
|
java.lang.String |
toString() |
public SmallMeanPoissonSampler(org.apache.commons.rng.UniformRandomProvider rng, double mean)
rng
- Generator of uniformly distributed random numbers.mean
- Mean.java.lang.IllegalArgumentException
- if mean <= 0
.public int sample()
sample
in interface DiscreteSampler
public java.lang.String toString()
toString
in class java.lang.Object
Copyright © 2016–2018 The Apache Software Foundation. All rights reserved.