Generate graphs
Moderator: General Moderators
- greyhoundcode
- Forum Regular
- Posts: 613
- Joined: Mon Feb 11, 2008 4:22 am
Generate graphs
I wish to generate graphs (bar and pie mostly) on the fly for a project in progress. I am aware of JpGraph and have played about with it - it is impressive, but the end result doesn't quite have the desired finesse (nice anti-aliasing and all that) that I seek.
The eZ Components graphing class is something special, and I have fallen in love with the way its graphs appear when outputted as SVG. Of course the problem with SVG is that it is unsupported by IE ("out of the box" at least).
Does anyone else have any opinions or experiences they might share about this? My dream is SVG smoothness in bitmap form!
The eZ Components graphing class is something special, and I have fallen in love with the way its graphs appear when outputted as SVG. Of course the problem with SVG is that it is unsupported by IE ("out of the box" at least).
Does anyone else have any opinions or experiences they might share about this? My dream is SVG smoothness in bitmap form!
Re: Generate graphs
If you wish fine grained control on exactly how everything looks, I'd go for protovis,
http://vis.stanford.edu/protovis/
or possibly one of the other js or flash graph solutions.
There's also the possibility of doing everything with HTML/CSS, but you have to like that
http://vis.stanford.edu/protovis/
or possibly one of the other js or flash graph solutions.
There's also the possibility of doing everything with HTML/CSS, but you have to like that
- greyhoundcode
- Forum Regular
- Posts: 613
- Joined: Mon Feb 11, 2008 4:22 am
Re: Generate graphs
Seems to generate SVG - but yeah a similar Flash solution could do the trick.matthijs wrote:I'd go for protovis,
http://vis.stanford.edu/protovis/
or possibly one of the other js or flash graph solutions.
Such as creating, positioning and colouring divs? Or do you mean something else?matthijs wrote:There's also the possibility of doing everything with HTML/CSS, but you have to like that
Re: Generate graphs
We are using amcharts
- greyhoundcode
- Forum Regular
- Posts: 613
- Joined: Mon Feb 11, 2008 4:22 am
Re: Generate graphs
Yes amCharts looks nice.
Re: Generate graphs
Could be divs. Or li's. Or stretching images. There are countless examples if you google css bar charts or graphs. here's a list of somegreyhoundcode wrote:Such as creating, positioning and colouring divs? Or do you mean something else?
http://speckyboy.com/2009/02/04/16-usab ... echniques/
The drawack of using CSS is that it can be a bit tricky, depending on your CSS skills. On the other hand, the advantages are:
1) Easy on the server side, you just pull out the raw data
2) Fast. No image drawing either on server or client side
3) Accessible. If you do it right. A screenreader or search machine can perfectly read a list of items but not a single image.
- greyhoundcode
- Forum Regular
- Posts: 613
- Joined: Mon Feb 11, 2008 4:22 am
Re: Generate graphs
Well I have to admit I hadn't thought of that approach - an interesting idea that I think I will take forward.
For some reason I had let myself become railroaded into thinking the output must be bitmap, Flash or SVG.
And of course the HTML/CSS approach would certainly present some efficiency savings over both creating a graph server side with GD or having to send a Flash object to render the data.
Re: Generate graphs
I've used the CSS technique when displaying survey results. Pretty easy because you just calculate a percentage, and then set the width to that percentage for some div/image. AWstats for one, uses this technique too.