package BD2; require Exporter; use GD::Graph::bars; our @ISA = qw("Exporter"); our @Exporter=qw($BalkenD uegabe); our @Exporter_OK=qw(); our $Version=1.00; ###### Art des Graphes ##### my $graph = new GD::Graph::bars(400, 400); ###### Attribute des Graphen ##### $graph->set( x_label => 'Gel-Nr.', y_label => 'Intensität', title => 'Dot-Analyse', y_max_value => 16, y_tick_number => 8, y_label_skip => 2, bar_spacing => 1 ); ###### Werte ###### sub uegabe { push (@Speicher, @_); for (0..5){ $data[0][$_]=$Speicher[$_]; $data[1][$_]=$Speicher[$_+6]; $data[2][$_]=$Speicher[$_+12]; } } #my @data = ( #["1st","2nd","3rd","4th","5th","6th","7th", "8th", "9th"], #[ 1, 2, 5, 6, 3, 1.5, 1, 3, 4], #[ 10, 12, 5, 9, 1, 2, 1, 7, 8] #); my $zeiger=\@data; ###### Ausgabe ####### $BalkenD=$graph->plot($zeiger)->png(); 1;