TimeSeries Questions

A discussion forum for JFreeChart (a 2D chart library for the Java platform).
Locked
newbie
Posts: 6
Joined: Tue Feb 13, 2007 9:07 am

TimeSeries Questions

Post by newbie » Mon Apr 09, 2007 7:56 am

Hi,
I am trying to draw multiple Range axis TimeSeries graph.
I am using the ChartFactory.createTimeSeriesChart(...) method and adding the multiple axis by something like:

XYPlot plot = chart.getXYPlot();
plot.setRangeAxis(1, axis2);
plot.setDataset(1, dataset);

All this seems to be working fine and I am able to see my chart being drawn nicely. But I have a few problems that I am not able to solve:
1. What is the maximum number of Range axis that I can add to the graph?
2. I want to show 10 Minutes of data at one time. so I used the following method:
axis.setFixedAutoRange(10*1000*60); // millis
This works but domain axis shows the ticks from the (current time - 10 ) minutes to current time . How can I get it to draw starting from the from the current time to current time+10 instead.


Any help is appreciated.
Regards...

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

Re: TimeSeries Questions

Post by david.gilbert » Tue Apr 10, 2007 10:42 am

newbie wrote:1. What is the maximum number of Range axis that I can add to the graph?
There is no limit, except the available space to draw the axes and the ability of the reader to decipher what it all means.
newbie wrote:2. I want to show 10 Minutes of data at one time. so I used the following method:
axis.setFixedAutoRange(10*1000*60); // millis
This works but domain axis shows the ticks from the (current time - 10 ) minutes to current time . How can I get it to draw starting from the from the current time to current time+10 instead.
Do you mean initially when there is less than 10 minutes worth of data? I don't know a good way to make that work, yet, but I agree that it would be nicer than what JFreeChart does now.
David Gilbert
JFreeChart Project Leader

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

Locked