Java Code Examples for org.jfree.chart.ChartFactory#createXYStepAreaChart()
The following examples show how to use
org.jfree.chart.ChartFactory#createXYStepAreaChart() .
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: XYStepAreaChartTests.java From astor with GNU General Public License v2.0 | 6 votes |
/** * Create a horizontal bar chart with sample data in the range -3 to +3. * * @return The chart. */ private static JFreeChart createChart() { // 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); XYDataset dataset = new XYSeriesCollection(series1); // create the chart... return ChartFactory.createXYStepAreaChart( "Step Chart", // chart title "Domain", "Range", dataset, // data PlotOrientation.VERTICAL, true, // include legend true, // tooltips true // urls ); }
Example 2
Source File: XYStepAreaChartTests.java From astor with GNU General Public License v2.0 | 5 votes |
/** * Create a horizontal bar chart with sample data in the range -3 to +3. * * @return The chart. */ 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); XYDataset dataset = new XYSeriesCollection(series1); return ChartFactory.createXYStepAreaChart("Step Chart", "Domain", "Range", dataset, true); }
Example 3
Source File: IndustriesPanel.java From computational-economy with GNU General Public License v3.0 | 5 votes |
protected ChartPanel createMarketDepthPanel(final Currency currency, final GoodType goodType) { final XYDataset dataset = ApplicationContext.getInstance().getModelRegistry() .getNationalEconomyModel(currency).marketDepthModel.getMarketDepthDataset(currency, goodType); final JFreeChart chart = ChartFactory.createXYStepAreaChart(goodType + " Market Depth", "Price", "Volume", dataset, PlotOrientation.VERTICAL, true, true, false); return new ChartPanel(chart); }
Example 4
Source File: HouseholdsPanel.java From computational-economy with GNU General Public License v3.0 | 5 votes |
protected ChartPanel createMarketDepthPanel(final Currency currency) { final XYDataset dataset = ApplicationContext.getInstance().getModelRegistry() .getNationalEconomyModel(currency).marketDepthModel.getMarketDepthDataset(currency, GoodType.LABOURHOUR); final JFreeChart chart = ChartFactory.createXYStepAreaChart(GoodType.LABOURHOUR + " Market Depth", "Price", "Volume", dataset, PlotOrientation.VERTICAL, true, true, false); return new ChartPanel(chart); }
Example 5
Source File: BanksPanel.java From computational-economy with GNU General Public License v3.0 | 5 votes |
protected ChartPanel createMarketDepthPanel(final Currency currency, final Currency commodityCurrency) { final XYDataset dataset = ApplicationContext.getInstance().getModelRegistry() .getNationalEconomyModel(currency).marketDepthModel.getMarketDepthDataset(currency, commodityCurrency); final JFreeChart chart = ChartFactory.createXYStepAreaChart( commodityCurrency.getIso4217Code() + " Market Depth", "Price", "Volume", dataset, PlotOrientation.VERTICAL, true, true, false); return new ChartPanel(chart); }