Bug#231730: floating-point value for max_val option is broken

Bill Allombert allomber at math.u-bordeaux.fr
Sat Mar 25 14:56:59 UTC 2006


On Sat, Mar 18, 2006 at 11:33:37PM +0200, Niko Tyni wrote:
> > The graph I get with woody libchart-perl:
> > <http://popcon.debian.org>
> > 
> > The new colours are unreadable and the number of ticks is not correct,
> > and the tick label include .000.
> > 
> > Any help how to solve this welcome. 
> 
> Hm. I think the number of ticks in 'Number of submissions' can be solved
> with 'max_y_ticks', as I mentioned in the previous mail. The 'precision'
> variable can be used to get rid of the .000 labels.


Hello Niko, 
now the colors are correct, but 'precision' does not work well: it just
round the label so you end up with several time the same label if there
is very few integral y values (say just 0 and 1).

Just try this script:

-----------
#! /usr/bin/perl -w

use Chart::LinesPoints;
@data=([2003,2004,2005],[0,0,1],[0,1,1],[1,1,1]);
$obj=Chart::LinesPoints->new (600,400);
$obj->set ('precision' => 0);
$obj->png ("foo.png",\@data);
-----------

You get three y-labels 0 and 3 y-labels 1.

The woody version did not have this problem.

Cheers,
Bill.




More information about the pkg-perl-maintainers mailing list