Question

I have an XYPlot in JFreeChart with multiple XYDatasets. JFreeChart creates a key at the bottom of the plot with an entry for each series by default. I would like to disable the drawing of entries for all of the series in one of my datasets. I do not want to disable the drawing of entries altogether. Is this possible without modifying the renderer? Thanks!

Was it helpful?

Solution

You should be able to do this directly by calling setSeriesVisible() or setBaseSeriesVisible() on your render.

For the legend at the bottom you can use setSeriesVisibleInLegend() or setBaseSeriesVisibleInLegend()

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top