Hi,
I am having a problem with my line graph. For horizontal axis I use the HorizontalDateAxis to display date. The line graph for most situation is displayed rather nicely. However, there are situations where there are no values at the beginning or end of the graph, the date range of the graph is trimmed. Is there any way to force the graph to to display the dates with no values specified?
I am not certain, but I think in the NumberAxis class there is a method setAutoRangeIncludesZero() that can do the job if the axis uses number instead of date. Is there a similar method for the DateAxis class?
Display graph with no values on DateAxis
Re: Display graph with no values on DateAxis
Hi Del,
By default, JFreeChart automatically sets the axis ranges to match the minimum and maximum values in your dataset (plus a small margin). But you can always override that by setting a range manually...use one of the setRange(...) methods inherited from the DateAxis class.
Regards,
Dave Gilbert
By default, JFreeChart automatically sets the axis ranges to match the minimum and maximum values in your dataset (plus a small margin). But you can always override that by setting a range manually...use one of the setRange(...) methods inherited from the DateAxis class.
Regards,
Dave Gilbert