1
votes

I generate this chart with Jfreechart lib

I would like to hide the labels in axis, but show only the first and the last value, How I can do?

Thank soo much!!

1

1 Answers

1
votes

I think you have to override NumberAxis.refreshTicks method (If you are using line chart). A bit similar example is available here :

JFreechart: Displaying X axis with values after specific units

When you would set only two tick values by using this function other values would be automatically gets invisible.