it's my fault. I should describe it more clearly.
I know where is the problem.
I parse a text and want to get identical words and its times. So I have a hash: key is "identical words" and value is "times".
I hope I could draw a lines picture (x-axis is identical word and y-axis is times). In other words, "times" is data argument and "identical words" is chxl argument in URI::GoogleChart.
my ($x, @y); $x="0:"; foreach (sort { $word2_hash{$b} <=> $word2_hash{$a} or $a cmp $b} +keys %word2_hash) { $x .= "|$_"; #add identical words push @y, $word2_hash{$_}; #add times } my $chart = URI::GoogleChart->new("lines", 400, 150, data => \@y,#it is OK to parse array_ref range_show => "left", range_round => 1, color => ["red"], chxl => "$x", # chxt => "x", ); #getstore($chart, "chart.png"); #print "get pic\n";
<Sorry for my wrong post. It could work if use array_ref/p>
I find where is my problem. The chxl seems have limit. If I decrease the identical words. I can get the picture. If I use a lot of identical words, I couldn't get the picture.
Thanks for all your reply.
In reply to Re^2: draw picture by google Chart
by HHCHANG
in thread draw picture by google Chart
by HHCHANG
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |