I want to write an application, where users will have to choose between different "configurations", and I am looking for a way to statistically validate the "balance" of those "configurations", to make the equally "attractive" to users. Ideally, I'd like to use a Java API, as it would make it easy to "round-trip" (the main application will be written in Java) by running the simulation that generates the data, then run an analysis on it, then modify the "configurations", and re-run the simulation, to see how near we are now to the desired state. I've had a solid background in math/statistics, but that was many, many years ago. So I'm looking for something where I can quickly get started, rather then a full-blown, but complex, system, which would require me to spend a lot of time refreshing my math/stats knowledge.

To rephrase, I'm looking foremost for an API that allows me to statistically analyse data in Java, rather the "create visualisation" (although, of course, creating visualisation would be useful to quickly validate the analysis code, but the visualisation could be generated by another program).

EDIT: Actually, I'm pretty good at Python too, but that would make the round-trip a bit more difficult.

  • $\begingroup$ Note that asking about how to set up and/or analyze your experiment is on topic here, but I doubt asking for an API reference is (see the help). $\endgroup$
    – Andy W
    Commented Dec 4, 2013 at 12:36
  • $\begingroup$ Check out Java R interface: rforge.net/JRI $\endgroup$ Commented Dec 4, 2013 at 12:38
  • $\begingroup$ @AndyW I understand that problem, but unfortunately, there does not seem to be any place on StacExchange to ask for that kind of thing, and I think that is a real need that should be "filled". $\endgroup$ Commented Dec 4, 2013 at 20:09
  • $\begingroup$ @MarcClaesen I have heard about R, and I really wasn't expecting a project like that, but I do not see how this contribute to my question, as *I would have to learn R to use it" ... :D (I wish I could, but I don't think I could find the time for that) $\endgroup$ Commented Dec 4, 2013 at 20:12

1 Answer 1


I can think of at least two native Java alternatives that you might look into. The first one is the cern.jet.stat package. It's part of a much larger project called Colt.

The second one is Weka. It's mainly conceived as an end-user GUI for machine learning, classification and clustering problems and the like, but it also supports more basic statistical operations, and crucially, it exposes an API.

I can pretty much guarantee you that neither of these will be particularly easy for you to learn to use well. If you want a really basic intro to Weka, there is actually a 5-lesson MOOC; it's no longer running but you can still view the videos, and each lesson is about an hour long and is further subdivided into about a half-dozen 10 minute videos. I'd recommend viewing the first two or three of these (i.e., 20-30 minutes of your time in total) from lesson one, in order to get a good intro to what Weka is and what it can do. After that you can probably skip the rest and move directly to the API in order to retrieve the classes that you would need to do your work.

  • $\begingroup$ Thanks! A few hours, or maybe even a whole weekend, worth of time investment is no problem; I'm just hoping for something that won't take weeks to learn. :) $\endgroup$ Commented Dec 4, 2013 at 20:15
  • $\begingroup$ The Colt project talks about "JDK ibm-1.4.1, RedHat 9.0", and says "Last published Sep 9, 2004"; it looks like it's "dead" (although that doesn't mean there is anything wrong with what is available). Weka, OTOH, looks very much alive. $\endgroup$ Commented Dec 4, 2013 at 20:36
  • $\begingroup$ There is a "quick" (80 pages) guide to Weka for programmers: amazon.com/Instant-Weka-How--Bo%C2%9Atjan-Kalu%C2%9E/dp/… $\endgroup$ Commented Dec 4, 2013 at 20:45

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.