mirror of
https://github.com/dkogan/feedgnuplot.git
synced 2025-05-05 22:11:12 +08:00
fix handling of empty curves
Ignore-this: b898c03e4df23a2d9c6c5fad7065aff4 darcs-hash:20090915194423-0cb85-e00bbfe44ec500ed844e2275571a9170bcd5e4aa.gz
This commit is contained in:
parent
33f62a8438
commit
3e6fabaf97
@ -268,11 +268,12 @@ sub plotStoredData
|
||||
print PIPE "set xrange [$xmin:$xmax]\n" if defined $xmin;
|
||||
|
||||
# get the options for those curves that have any data
|
||||
my @extraopts = map {$_->[0]} grep {@$_ > 1} @curves;
|
||||
my @nonemptyCurves = grep {@$_ > 1} @curves;
|
||||
my @extraopts = map {$_->[0]} @nonemptyCurves;
|
||||
|
||||
print PIPE 'plot ' . join(', ' , map({ '"-"' . $_} @extraopts) ) . "\n";
|
||||
|
||||
foreach my $buf (@curves)
|
||||
foreach my $buf (@nonemptyCurves)
|
||||
{
|
||||
# send each point to gnuplot. Ignore the first "point" since it's the
|
||||
# options string
|
||||
|
Loading…
Reference in New Issue
Block a user