One that would, for example, allow me to create a Poisson random variable with specified lambda and generate random numbers with it, or to calculate the marginals from a discrete joint probability distribution function?
Or should I roll my own? (This is just for fun, I just want to play around with probability a bit, so no practical uses yet 🙂 )
Commons Math has a class called PoissonDistribution, from which you can sample random values with
sample()Also, if you want to play around with probability, you should check out R, a language custom-built for probability programming (that also seems to have a pretty vibrant SO presence)