Difference between revisions of "Data Visualization with Java"
From Self-Organization Wiki
(→JChart2D Library) |
|||
Line 4: | Line 4: | ||
* Webpage and download: [http://jchart2d.sourceforge.net/index.shtml] | * Webpage and download: [http://jchart2d.sourceforge.net/index.shtml] | ||
− | The library is very easy to | + | The library is very easy to use because you don't have to spend a lot of time on making adjustments. You can create for example static line charts and dynamic line charts but you cannot create Pie Charts or Bar Charts. |
===Code Examples=== | ===Code Examples=== |
Revision as of 08:08, 5 July 2010
Contents
JChart2D Library
- License Model: open source (LGPL license)
- Webpage and download: [1]
The library is very easy to use because you don't have to spend a lot of time on making adjustments. You can create for example static line charts and dynamic line charts but you cannot create Pie Charts or Bar Charts.
Code Examples
The follwing code snipped creates a static XY Diagramm
import info.monitorenter.gui.chart.Chart2D; import info.monitorenter.gui.chart.ITrace2D; import info.monitorenter.gui.chart.traces.Trace2DSimple; import javax.swing.JFrame; public class MinimalStaticChart { private MinimalStaticChart() { super(); } public static void main(String[]args){ Chart2D chart = new Chart2D(); // Create a chart: ITrace2D trace = new Trace2DSimple(); // Create an ITrace: chart.addTrace(trace); // Add the trace to the chart: // Create the Points and add them to the trace for(int i=10000;i>=0;i--){ trace.addPoint(Math.cos(3*(double)i/1000.0),Math.sin(4*(double)i/1000.0)); } // Show the chart on the screen JFrame frame = new JFrame("MinimalStaticChart"); frame.getContentPane().add(chart); frame.setSize(400,300); frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE); frame.setVisible(true); } }
which looks like this:
Screenshot
ExampleChart Library
- License Model: open source (LGPL license)
- Webpage and download: [2]
The library bla bla bla .....
Code Examples
The follwing code snipped creates a pie chart together with a life update Venn Diagramm
code code code code code? // comment code code code !!
which looks like this:
Screenshot
Other Libraries
The following Java libraries looked promising, but turned out to be not recommendable:
- M$$-Chart commercial license (500 € per license)
- Crash-Chart beta version, still needs a lot of development, crashes frequently
- Bad-Chart bad performance, missing important chart types like xy-Diagrams