Sample a poisson conditional on it being even or odd This function is only computationally efficient when lambda is small.
sample_parity_poisson(lambda, parity = "even")
lambda | Poisson parameter. |
---|---|
parity | Either "even" or "odd". |
Scalar, a sample from the poisson conditional on the specified parity