Beefy Boxes and Bandwidth Generously Provided by pair Networks
Syntactic Confectionery Delight

State of the Ch(art) in Perl

by doc_faustroll (Scribe)
on Jan 22, 2010 at 21:37 UTC ( #819055=perlquestion: print w/replies, xml ) Need Help??
doc_faustroll has asked for the wisdom of the Perl Monks concerning the following question:

I see a dizzying array of options for charting on the CPAN.

Do you have an opinion on which modules are best for use on a Linux workstation for bar and line charting? Which modules do you like and why? Have you used the Google Chart API through a perl module? Did the Google API service your needs or did it disappoint?

I'd appreciate any thoughtful opinions or evaluations of the state of the ch(art) in Perl.

Replies are listed 'Best First'.
Re: State of the Ch(art) in Perl
by Utilitarian (Vicar) on Jan 22, 2010 at 22:24 UTC
    Hi faustroll, I find GD::Graph to be excellent, it took a little while to get the hang of initially, I was using Perl to build data sets, write gnuplot directive files and call gnuplot until I got comfortable with it. Would strongly recommend

    print "Good ",qw(night morning afternoon evening)[(localtime)[2]/6]," fellow monks."
Re: State of the Ch(art) in Perl
by molecules (Monk) on Jan 22, 2010 at 23:32 UTC

    I have been very impressed with ChartDirector, even though it costs $99. I'm trying to get my boss to pay for it. I've been using a trial version and am pleased with the results. I've also seen that they have great customer support.

    I've also checked into a couple of very good Open Source modules:

    Changing the symbols is easy (for me anyway) Modifying the spacing between data points is very difficult (i.e. not starting our data directly on the y axis) This also outputs text as text elements, thus allowing me to generate PDFs generated from it in which the text is searchable.

    Modifying the spacing between data points is easy (i.e. not starting our data directly on the y axis) Changing the symbols is extremely difficult. Text is output as drawing commands. PDFs generated from the output will not have searchable text.

    Hope this helps!


    ChartDirector works great for raster (e.g. PNG) or for SVG (i.e. vector) graphics.

    I'm specifically working with SVG files. To output SVG using ChartDirector call the method enableVectorOutput() after creating the chart object, then use a file name ending in '.svg' when you output the file:

    $chart_obj->enableVectorOutput(); . . . $chart_obj->makeChart('chart.svg');

Re: State of the Ch(art) in Perl
by zentara (Archbishop) on Jan 23, 2010 at 11:53 UTC
Re: State of the Ch(art) in Perl
by molecules (Monk) on Jan 23, 2010 at 12:13 UTC
Re: State of the Ch(art) in Perl
by mw487 (Sexton) on Jan 23, 2010 at 11:37 UTC
    I am going to go against the flow here and point out that Spreadsheet::WriteExcel recently added initial support for charting (Gnumeric and compatible). While I know that Excel charting itself is quite primitive, it does have the advantage of being commonly available, so your chart users can build on your efforts.

    "The Spreadsheet::WriteExcel Perl module can be used to create a cross-platform Excel binary file. Multiple worksheets can be added to a workbook and formatting can be applied to cells. Text, numbers, formulas, hyperlinks, images and charts can be written to the cells.

    The file produced by this module is compatible with Excel 97, 2000, 2002, 2003 and 2007.

    The module will work on the majority of Windows, UNIX and Mac platforms. Generated files are also compatible with the Linux/UNIX spreadsheet applications Gnumeric and"

Re: State of the Ch(art) in Perl
by $self (Friar) on Jan 23, 2010 at 09:48 UTC

    I am also a happy user of GD::Graph - except when it comes to adding text: the anti-aliasing never really seems to work out very well.

    The next time I need some graphs I'm planning to check out Imager, which looks very promising.

Re: State of the Ch(art) in Perl
by ambrus (Abbot) on Jan 23, 2010 at 18:06 UTC
Re: State of the Ch(art) in Perl
by jmcnamara (Monsignor) on Jan 24, 2010 at 19:29 UTC

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: perlquestion [id://819055]
Approved by keszler
Front-paged by MidLifeXis
and all is quiet...

How do I use this? | Other CB clients
Other Users?
Others surveying the Monastery: (6)
As of 2017-02-25 10:38 GMT
Find Nodes?
    Voting Booth?
    Before electricity was invented, what was the Electric Eel called?

    Results (365 votes). Check out past polls.