Package org.jfree.data.xy

Examples of org.jfree.data.xy.XYBarDataset


    private static JFreeChart createChart() {
        XYSeries series1 = new XYSeries("Series 1");
        series1.add(1.0, 1.0);
        series1.add(2.0, 2.0);
        series1.add(3.0, 3.0);
        IntervalXYDataset dataset = new XYBarDataset(new XYSeriesCollection(
                series1), 1.0);
        return ChartFactory.createXYBarChart("XY Bar Chart", "Domain", false,
                "Range", dataset);
    }
View Full Code Here


        d2.addSeries(s3);
        d2.addSeries(s4);
        d2.addSeries(s5);

        XYBarRenderer r = new XYBarRenderer();
        XYPlot plot = new XYPlot(new XYBarDataset(d1, 1.0), new NumberAxis("x"),
                new NumberAxis("y"), r);
        plot.setDataset(1, new XYBarDataset(d2, 2.0));
        /*JFreeChart chart =*/ new JFreeChart(plot);
        LegendItem li = r.getLegendItem(1, 2);
        assertEquals("S5", li.getLabel());
        assertEquals(1, li.getDatasetIndex());
        assertEquals(2, li.getSeriesIndex());
View Full Code Here

        // create a dataset...
        XYSeries series1 = new XYSeries("Series 1");
        series1.add(1.0, 1.0);
        series1.add(2.0, 2.0);
        series1.add(3.0, 3.0);
        IntervalXYDataset dataset = new XYBarDataset(
            new XYSeriesCollection(series1), 1.0
        );
        // create the chart...
        return ChartFactory.createXYBarChart(
View Full Code Here

TOP

Related Classes of org.jfree.data.xy.XYBarDataset

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.