Hi,
I am trying to create a function that would return another function that generates draws from a beta distribution. Something like this:
(defun make-beta-generator (a b) (letm ((rng (random-number-generator *mt19937* 0))) (lambda () ;; of course this won't work, letm deallocated rng (beta-rd rng a b))))
As the comment says, this does not work. Is there a way to prevent letm from deallocating rng (or achieve the effect I want by some other means)?
Thanks,
Tamas