tags:

views:

346

answers:

2

I'm looking to draw a 3d bar graph similar to the one below

alt text

My problem is that I can't seem to find any useful library that can do this for me, any classes available that can do this for me. I tried pchart but this does not seem to work for this, only for 3d pie charts

+3  A: 

Maybe here you can find something suitable? http://www.aditus.nu/jpgraph/features%5Fgallery.php#BarPlots

Palantir
A: 

I assume you want to use PHP for the graphs to ensure that everyone who views the site can see them? Why not use a JS library such as Plotr to create the spangly 3D version, but fall back on CSS for those users without the correct browser support;

http://speckyboy.com/2009/02/04/16-usable-css-graph-and-bar-chart-tutorials-and-techniques/

EDIT

If the graph is being sent via email then you can't use JS, but there's no reason why you can't use CSS. Get PHP to output a list, or a series of inputs (whatever best fit's your purpose), send the email in an HTML format, and use CSS to style the HMTL using one of the techniques illustrated in the link above.

Also, using PHP to generate static images will present other issues, most notably getting through user's spam filters and your own bandwidth, not to mention how much of a waste of CPU cycles it is to process these images when a bit of HTML / CSS trickery would achieve the same effect.

MatW
I need to use PHP, since this script isn't going to run in a browser, accessing it via the command line and then mailing users with there stats in a graph
Roland
Ahh, OK. That's pretty important, might be worth adding that to the question so people can help in a more specific way. I'll make a edit to my answer above...
MatW