multi series continuous axis chart q

A discussion forum for JFreeChart (a 2D chart library for the Java platform).
Locked
derek

multi series continuous axis chart q

Post by derek » Wed Jun 01, 2005 11:36 am

is it possible to have multiple series show beside each other rather than on top of each other on a continuous or timeseries axis on a bar chart?

for example having something like:

Code: Select all

*=series1
+=series2

                +
*+   *       +
*+   *+   *+
-----------------
0     1     2 
instead of the default which would have + and * layered on top of each other, taking away certain visual aspects of the graph.


Thanks.

derek

Post by derek » Wed Jun 01, 2005 11:37 am

argh the + values for x=2 didn't show up properly but hopefully it is clear what I mean.

derek

Post by derek » Wed Jun 01, 2005 6:20 pm

I just read my message from earlier and realised it doesn't make much sense. Let me make it clearer.

Using an xybarchart with multi series I have been able to produce the following graph:

Image


However I much prefer the following layout which I have created by editing the first graph in a paint program.

Image

Using jfreechart is it possible to produce a graph like this?

Thanks, derek.

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 Jun 01, 2005 6:42 pm

Use ClusteredXYBarRenderer, I think it does what you want.
David Gilbert
JFreeChart Project Leader

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

Guest

Post by Guest » Thu Jun 02, 2005 12:00 pm

okay thanks david that works well.

another question I have is is it possible to group data on a continuous x axis?

for example instead of having a value for each 1 -i.e. (1,1), (2,6), (3,2), (4,10), (where (x,y)) is it possible to group the data such as (1-10,40), (11-20,50), (21-30,30).. etc?

thanks again.

Rahul Gupta
Posts: 11
Joined: Wed Apr 20, 2005 1:55 pm
Location: India

Post by Rahul Gupta » Fri Jun 03, 2005 10:08 am

Try trough StackedBarChart Example. I think it should solved your problem.
Rahul K. Gupta

Locked