How to hide JFreeChart XYSeries yaxis?

jacknad picture jacknad · Oct 20, 2010 · Viewed 8.1k times · Source

Is there a way to hide a JFreeChart XYSeries yaxis? The yaxis is meaningless on logic analyzer display.

Answer

trashgod picture trashgod · Oct 20, 2010

You can use setVisible(), as shown below.

XYPlot plot = (XYPlot) chart.getPlot();
ValueAxis range = plot.getRangeAxis();
range.setVisible(false);