Custom rng function

Just to complement, rejection sampling can be implemented in pure Stan, e.g. Sampling from truncated lognormal - #2 by bbbales2

2 Likes