#!/usr/bin/perl use strict; use warnings; use Chart::Mountain; my $filename = $ARGV[0]; my $g = Chart::Mountain->new(1000,500); $g->add_datafile( "$filename", 'set' ); $g->set ( 'title' => 'Video Server Play Daily Hourly Report', 'grid_lines' => 'true', 'y_label' => 'Numero Streams', 'x_label' => 'Dates', 'include_zero' => 1, 'x_ticks' => 'vertical', 'tick_label_font' => (GD::Font->Giant), 'title_font' => (GD::Font->Giant), 'colors' => {'dataset0' => [0,255,0]}, 'integer_ticks_only' => 1, 'misc' => [0,0,0], ); $g->jpeg ("graph.jpg"); #### 29/04/2010-00.00 29/04/2010-00.30 29/04/2010-01.00 29/04/2010-01.30 29/04/2010-02.00 29/04/2010-02.30 29/04/2010-03.00 29/04/2010-03.30 29/04/2010-04.00 29/04/2010-04.30 29/04/2010-05.00 29/04/2010-05.30 29/04/2010-06.00 29/04/2010-06.30 29/04/2010-07.00 29/04/2010-07.30 29/04/2010-08.00 29/04/2010-08.30 29/04/2010-09.00 29/04/2010-09.30 29/04/2010-10.00 29/04/2010-10.30 29/04/2010-11.00 29/04/2010-11.30 29/04/2010-12.00 29/04/2010-12.30 29/04/2010-13.00 29/04/2010-13.30 29/04/2010-14.00 29/04/2010-14.30 29/04/2010-15.00 29/04/2010-15.30 29/04/2010-16.00 29/04/2010-16.30 29/04/2010-17.00 29/04/2010-17.30 29/04/2010-18.00 29/04/2010-18.30 29/04/2010-19.00 29/04/2010-19.30 29/04/2010-20.00 29/04/2010-20.30 29/04/2010-21.00 29/04/2010-21.30 29/04/2010-22.00 29/04/2010-22.30 29/04/2010-23.00 29/04/2010-23.30 2 3 1 1 2 2 1 2 2 3 2 1 1 1 1 4 3 3 2 1 2 3 1 1 2 2 1 2 2 3 2 1 1 1 1 4 3 3 2 1 2 3 1 1 2 2 1 2