Graph mit gnuplot
roman lenz
- perl
hi hi
ich möchte einen Graph mit dem gnuplot-Modul erstellen.
Hat schon jemand erfahrungen damit gesammelt?
ich habe das Modul einfach in mein perlverzeichnis kopiert und will es mit diesem script testen. leider bekommen ich keine fehlermeldung aber leider auch keine bilddatei :-((
kennt sich jemand damit aus??
besten dank für die hilfe
bis bis roman
#!D:\Perl\bin\perl.exe -w
use CGI::Carp qw(fatalsToBrowser);
use strict;
use CGI qw(:standard);
use Chart::Graph::Gnuplot qw(gnuplot);
my $cgi = new CGI; # neues Objekt erstellen
my $date_format;
gnuplot({"title" => "foo",
"x2-axis label" => "bar",
"logscale x2" => "1",
"logscale y" => "1",
"output type" => "png",
"output file" => "gnuplot1.png",
"xtics" => [ ["small\nfoo", 10], ["medium\nfoo", 20], ["large\nfoo", 30] ],
"ytics" => [10,20,30,40,50]},
"xdata" => "time",
"format" => ["x", "%m/%d"],
"timefmt"=> $date_format,
"extra_opts" => "set key left top Left",
[{"title" => "data1",
"type" => "matrix"}, [[1, 10],
[2, 20],
[3, 30]] ],
[{"title" => "data2",
"style" => "lines",
"type" => "columns"}, [8, 26, 50, 60, 70],
[5, 28, 50, 60, 70] ],
[{"title" => "data3",
"style" => "lines",
"type" => "file"}, "samplefile"],);
__ENDE__