- Well-designed API consistent with modern Java API design standards
- Efficient and robust decision tree learner
- Random forests implementation
- Meta-parameter optimizer
- Released under the LGPL v3 free software license
- 2nd March, 2015: 0.6.0 released, major API redesign and refactor
Ask questions and contribute
Come say "Hi!" on our Discussion Forum, or improve QuickML and submit a pull request through GitHub. What to help? Take a look at our open issues and see if there is anything you can tackle, fork our code, then submit a pull request.
Documentation of QuickML is currently lagging significantly behind functionality, but the API is fairly well defined and should be mostly self-explanatory using the examples below as a starting point, just start poking around the source code, particularly the unit tests. You can also improve this site by editing this file.
Please also note that the QuickML API remains subject to change, and will continue to do so until 1.0 (although, of course, we will only make such changes if we're convinced they're necessary to make the API as good as it can be.
How to use
Add the following repository to your Maven pom.xml file:
<repository> <id>jitpack.io</id> <url>https://jitpack.io</url> </repository>Add the following repository to your Maven pom.xml file:
<dependency> <groupId>com.github.sanity</groupId> <artifactId>quickml</artifactId> <version>Find latest release here</version> </dependency>
Build a simple predictive model
Here we train a random forest on the well-known Fisher Iris dataset, which is included with QuickML for your convenience. We then generate a prediction for a particular set of input attributes:
import quickml.data.*; import quickml.supervised.classifier.randomForest.*; // ... List<ClassifierInstance> irisDataset = PredictiveAccuracyTests.loadIrisDataset(); final RandomForest randomForest = new RandomForestBuilder().buildPredictiveModel(irisDataset); AttributesMap attributes = new AttributesMap(); attributes.put("sepal-length", 5.84); attributes.put("sepal-width", 3.05); attributes.put("petal-length", 3.76); attributes.put("petal-width", 1.2); System.out.println("Prediction: " + randomForest.getProbability(attributes, "Iris-virginica"));