X-Axis labels and large data sets

A discussion forum for JFreeChart (a 2D chart library for the Java platform).
Locked
prophecy
Posts: 3
Joined: Wed Feb 23, 2005 6:57 am

X-Axis labels and large data sets

Post by prophecy » Wed Feb 23, 2005 8:01 am

As the datasets get large, the x-axis labels get squished down until it looks like a row of dots. I think it should handle it more elegantly like jcharts does where it will skip labels when they don't all fit on the axis.

david.gilbert
JFreeChart Project Leader
Posts: 11734
Joined: Fri Mar 14, 2003 10:29 am
antibot: No, of course not.
Contact:

Post by david.gilbert » Wed Feb 23, 2005 10:53 am

In 98% of cases, if your chart makes sense with some category labels hidden, then your categories aren't really categories at all, they're values of some sort. In those cases, you should be using an XYPlot.

Someone once contributed some code for hiding categories in the axis - but it stopped working when the label rotation options were added, and so it was removed. I have no plans to put it back, although I'd consider adding a separate LabelSkippingCategoryAxis class if someone wants to write the code.
David Gilbert
JFreeChart Project Leader

:idea: Read my blog
:idea: Support JFree via the Github sponsorship program

Alfred63
Posts: 22
Joined: Mon Jun 21, 2004 9:38 pm

Post by Alfred63 » Wed Feb 23, 2005 4:50 pm

I struggled with a similar problem of trying to show a mountain of data in one window, in our case, trying to have a months worth of hours displayed via a TimeSseries.

We actually ran into a bug with the TimeSeries itself. But we took a step back and decided that really, it would be better for the user if we simply added a previous and next button at the bottom of the graph.

Everyone seems to love it. They can quickly take a look at an enormous data range by simply clicking next.

prophecy
Posts: 3
Joined: Wed Feb 23, 2005 6:57 am

Post by prophecy » Wed Feb 23, 2005 6:00 pm

It is time based, but I don't want to have to use the Time Series because then I have to figure out what range it is when making the graph (Hour, Day, Month?) because the user can choose what time range they want to see. For example, they can choose to breakdown hourly from date X to date Y or monthly from date X to date Y and the x-axis labels are created in our system.

Is there a Time Series that you can just give it labels or something?

Locked