Secondary « Axis « JFreeChart Q&A

1. Hide Secondary Axis and Legend Key

Hello, I need to be able to not show the numbers on a secondary axis, and also, i plotted a line on the chart just to have a horizontal line at each quartile, not giving the line a name at all, but the box is showing in the legend where it would usually associate the color of a line to the ...

2. set color for secondary axis TimeSeries

old code: subplot1.setRenderer(1, new StandardXYItemRenderer()); new code: final XYItemRenderer renderer1a = new StandXYItemRenderer(); subplot1.setRenderer(1,renderer1a); renderer1a.setSeriesPaint(0,Color.GREEN); ==secondary axis series1 renderer1a.setSeriesPaint(1,Color.GREEN); ==secondary axis series2

4. setRenderer for secondary axis causes nullpointer exception

Hello, Just started using JFree charts today. Although I am able to run a similar demo successfully, I am having difficulty getting a multiple axis line chart to show up correctly. It seems like it does not like it when I do a setRenderer(1, renderer2). I get a NullPointerException - Exception in thread "main" java.lang.NullPointerException at org.jfree.chart.renderer.category.LineAndShapeRenderer.drawItem( The same renderer works ...

5. secondary XAxis with Distribution 1.0.13

Hey together I have some problems by using the NumberAxis in jFreeChart. My Problem is the following: I have one Dataset in an XY - Bar - Chart. Only one. Now i want to get an secondary Y - Axis on the right hand side of the Chart. Currently i got this Axis (see in Screenshot) but the Range is wrong. ...

6. Annotation On Secondary Range Axis

Hello, I am using annotation to display some text on XYPlot chart, with two Y axis. plot.addAnnotation(annotation) works only with the main range axis, but the Y value for the second Y access is outside the range of the main Y axis. I don't see addSecondaryAnnotation method. How can I set annotations on the secondary axis? Thanks, Kamal