Bayesian computation in Java?

John Payne writes:

I am writing a Java program to do ecosystem modeling and we wish to use Bayesian MCMC methods for parameter estimation. I am interested in finding flexible, customizable Bayesian MCMC code that can be called in Java. I looked at documentation for JAGS, BUGS, and also Gregory Warnes’s Hydra program (which is in Java). I have been unable to get a reply from Dr. Warnes but it seems Hydra is no longer being supported. As far as I can tell, BUGS is written in Component Pascal, which I am ignorant about. I have never tried JAGS; would you have any advice as to which avenue would be the most fruitful to pursue?

My reply: Right now, I think Jags is probably the best way to go. But others might have other suggestions here.

5 thoughts on “Bayesian computation in Java?

  1. Kevin Murphy has a summary of software for graphical models and Bayesian networks here. It is a nice overview, although I have to say that he mistakenly lists JAGS as being written in Java. It is, in fact, written in C++.

  2. YADAS (yadas.lanl.gov) is written in Java, and I think I can claim with some justice that it is flexible. It has not proved to be an intuitive option for many people other than me, but you may find it useful, and a potential advantage of using software with a very small user group is you might hope to get the developer to answer your questions!

  3. I've written MCMC code in Java using the COLT libraries. If you just need to sample and evaluate PDFs, colt.jet.stat and colt.jet.random support a reasonable set of probability distributions. This approach is not quite as automated as something like BUGS or BNT, for better or worse.

  4. Thank you all for your comments. It seems less is written in Java than I anticipated. Kevin Murphy's excellent table forced me to learn a lot about how models and methods are classified; Yadas and Blaise (if available) seem to have potential.

    Since I am still struggling with the classification, I would appreciate comments on whether this problem is amenable to one or more of the graphical methods, or could be thought of as an Infinite Relational Model:

    We would like to evaluate the data support for different potential food web structures. In a simple food web, each node represents the total mass of a species in an ecosystem. The connections between nodes describe the rate at which species eat each other (other interactions besides predation can also be modeled). To parameterize a food web model, you must describe the strength and direction of those interactions, but there are usually few data and many (hundreds or more) parameters. However, some information, particularly on the strength of connections between species, can be gained by observing how the mass of different species changes when the system is perturbed.

Comments are closed.