use strict; use GD::Graph::lines; my @data = ( [1, 2, 3, 4, 5, 6, 7, 8, 9,], [ 8, 8.25, 8.5, 8.35, 8.76, 8.21, 8.6, 8.8, 8.5], [ 7.4, 7.6, 7.8, 7.9, 7.4, 8.5, 7, 7.87, 8.34], [ 4, 5, 6, 5.6, 5.5, 6.1, 6.3, 5.2, 5.6]); my $graph = new GD::Graph::lines (600, 400); $graph->set( title => "Blah, Blah, Blah", x_label => 'X axis label', y_label => 'Y axis label', boxclr => '#C0C0C0' ); ## Next code snippet goes here $graph->set_legend("data set 1", "data set 2", "data set 3"); print "Content-type: image/png\n\n"; binmode(STDOUT); print $graph->plot(\@data)->png(); #### $graph->set( y_min_value => 6, y_max_value => 10, x_min_value => 3, x_max_value => 7 );