JFreeChart is a very popular open source library for plotting written in Java. It is not specifically designed with scientific plotting in mind. However, you can easily do most types of common scientific plots with it. The advantage of using this library is that it is very well supported and has been around for a longtime. This means that it is probably not going anywhere soon, which is a risk with many of the newer libraries that may not have the required developer power to keep going.
To use JFreeChart in your project, you need to download it and then put it in the lib
directory of your project. Download JFreeChart by going to the following website:
http://www.jfree.org/jfreechart/
After downloading the .zip
file containing the library, copy the lib
folder from the archive to the lib
folder under your project tree. This will make the library available to your Scala program when you run it using SBT. Without further ado, let's examine...