mirror of
https://github.com/dkogan/feedgnuplot.git
synced 2025-09-19 03:38:08 +08:00
Compare commits
66 Commits
debian/1.4
...
debian/1.5
Author | SHA1 | Date | |
---|---|---|---|
![]() |
0c209a8a2a | ||
![]() |
04f966ea17 | ||
![]() |
bdb9919c39 | ||
![]() |
4e85f991c4 | ||
![]() |
2e6c9d6ea3 | ||
![]() |
c4eef7a167 | ||
![]() |
7e1e6af184 | ||
![]() |
e9c9ff02e4 | ||
![]() |
2f9a6acdb3 | ||
![]() |
5e0869dc25 | ||
![]() |
592ce20d1f | ||
![]() |
bad9ac9732 | ||
![]() |
3c14e4e106 | ||
![]() |
373b97092e | ||
![]() |
e4523f97e7 | ||
![]() |
d73118087a | ||
![]() |
b8111af563 | ||
![]() |
fb76985239 | ||
![]() |
2b7dd9dbc8 | ||
![]() |
a022064a5c | ||
![]() |
54fc8c625d | ||
![]() |
8bb0c3a7d8 | ||
![]() |
dda83b2c27 | ||
![]() |
3a28d5fed9 | ||
![]() |
29f4f5a368 | ||
![]() |
55faefec8b | ||
![]() |
77f54da873 | ||
![]() |
b5275d6386 | ||
![]() |
481f18a5fb | ||
![]() |
87a4069a5a | ||
![]() |
dac7e2a2d4 | ||
![]() |
3ac5b1b9f3 | ||
![]() |
5772f8894f | ||
![]() |
958c6364c3 | ||
![]() |
40fea5eb7f | ||
![]() |
016c7ebfa9 | ||
![]() |
744239b7b7 | ||
![]() |
0c06f72d5d | ||
![]() |
350b2db022 | ||
![]() |
ba0f2eee08 | ||
![]() |
778825bd34 | ||
![]() |
9237811ed0 | ||
![]() |
69285d7df1 | ||
![]() |
e514b24e39 | ||
![]() |
88eeff7890 | ||
![]() |
aedbc28afe | ||
![]() |
e167e057d3 | ||
![]() |
38e92c5ba9 | ||
![]() |
e865871492 | ||
![]() |
0f85110a38 | ||
![]() |
811d0d45ab | ||
![]() |
5cf4acca62 | ||
![]() |
83d4e66ea5 | ||
![]() |
c2c327953d | ||
![]() |
319e86b667 | ||
![]() |
938e360e84 | ||
![]() |
d5e8906946 | ||
![]() |
e8f9e09090 | ||
![]() |
9df57fb65f | ||
![]() |
69bd05eddb | ||
![]() |
ca61de7441 | ||
![]() |
851eb46aa8 | ||
![]() |
f2ac9c91b8 | ||
![]() |
e79659a10d | ||
![]() |
2aa51d2a60 | ||
![]() |
3bf2fa43ef |
63
Changes
63
Changes
@@ -1,3 +1,66 @@
|
|||||||
|
feedgnuplot (1.54)
|
||||||
|
|
||||||
|
* Added --every and --everyall to decimate the input data
|
||||||
|
* --timefmt can be used with --histogram
|
||||||
|
|
||||||
|
-- Dima Kogan <dkogan@debian.org> Fri, 17 Apr 2020 14:06:55 -0700
|
||||||
|
|
||||||
|
feedgnuplot (1.53)
|
||||||
|
|
||||||
|
* Full support for all 4 axes. Added --x2...
|
||||||
|
|
||||||
|
-- Dima Kogan <dkogan@debian.org> Wed, 08 Jan 2020 18:55:29 -0800
|
||||||
|
|
||||||
|
feedgnuplot (1.52)
|
||||||
|
|
||||||
|
* Added --squarexy and --square-xy as synonyms to --square_xy
|
||||||
|
|
||||||
|
-- Dima Kogan <dima@secretsauce.net> Sun, 25 Aug 2019 15:32:37 -0700
|
||||||
|
|
||||||
|
feedgnuplot (1.51)
|
||||||
|
|
||||||
|
* Added .gp "terminal" to create self-plotting gnuplot files
|
||||||
|
|
||||||
|
-- Dima Kogan <dima@secretsauce.net> Sat, 29 Sep 2018 10:56:30 -0700
|
||||||
|
|
||||||
|
feedgnuplot (1.50)
|
||||||
|
|
||||||
|
* Script waits for the plot window to close before exiting
|
||||||
|
Instead of sleeping forever. This is really nice! I no longer need
|
||||||
|
to quit the plot window AND then C-c. Quitting the plot window is
|
||||||
|
now sufficient
|
||||||
|
* by default --image sets range noextend
|
||||||
|
* tab-completion knows about the fnormal distribution
|
||||||
|
|
||||||
|
-- Dima Kogan <dkogan@debian.org> Fri, 24 Aug 2018 13:11:05 -0700
|
||||||
|
|
||||||
|
feedgnuplot (1.49)
|
||||||
|
|
||||||
|
* --vnl now works with plots that have rangesize > 1
|
||||||
|
* zsh completion: --xlen argument isn't optional
|
||||||
|
|
||||||
|
-- Dima Kogan <dima@secretsauce.net> Fri, 16 Mar 2018 13:52:28 -0700
|
||||||
|
|
||||||
|
feedgnuplot (1.48)
|
||||||
|
|
||||||
|
* --vnlog works properly with --domain
|
||||||
|
|
||||||
|
-- Dima Kogan <dima@secretsauce.net> Sat, 24 Feb 2018 12:33:50 -0800
|
||||||
|
|
||||||
|
feedgnuplot (1.47)
|
||||||
|
|
||||||
|
* Fixed typo. Everything is un-broken now
|
||||||
|
|
||||||
|
-- Dima Kogan <dima@secretsauce.net> Fri, 23 Feb 2018 10:21:13 -0800
|
||||||
|
|
||||||
|
feedgnuplot (1.46)
|
||||||
|
|
||||||
|
* Added --tuplesize and --tuplesizeall as alternatives to --rangesize
|
||||||
|
and --rangesizeall. Both forms are supported.
|
||||||
|
* Vnlog integration
|
||||||
|
|
||||||
|
-- Dima Kogan <dima@secretsauce.net> Thu, 22 Feb 2018 23:37:54 -0800
|
||||||
|
|
||||||
feedgnuplot (1.45)
|
feedgnuplot (1.45)
|
||||||
|
|
||||||
* zsh completion: --hardcopy, --image suggest filenames
|
* zsh completion: --hardcopy, --image suggest filenames
|
||||||
|
9
INSTALL
9
INSTALL
@@ -10,4 +10,11 @@ Without a package, an installation can be done with
|
|||||||
make
|
make
|
||||||
make install
|
make install
|
||||||
|
|
||||||
This installs feedgnuplot to /usr/local. Adjust the paths as required
|
This installs feedgnuplot to /usr/local. Adjust the paths as required.
|
||||||
|
|
||||||
|
Also, note that this is a self-contained utility. Usually running from the tree
|
||||||
|
works just fine:
|
||||||
|
|
||||||
|
git clone https://github.com/dkogan/feedgnuplot.git
|
||||||
|
cd feedgnuplot/bin
|
||||||
|
./feedgnuplot ...
|
||||||
|
@@ -1 +0,0 @@
|
|||||||
bin/feedgnuplot
|
|
1009
README.pod
Normal file
1009
README.pod
Normal file
File diff suppressed because it is too large
Load Diff
646
bin/feedgnuplot
646
bin/feedgnuplot
@@ -16,7 +16,7 @@ use Pod::Usage;
|
|||||||
use Time::Piece;
|
use Time::Piece;
|
||||||
|
|
||||||
# Makefile.PL assumes this is in ''
|
# Makefile.PL assumes this is in ''
|
||||||
my $VERSION = '1.45';
|
my $VERSION = '1.54';
|
||||||
|
|
||||||
my %options;
|
my %options;
|
||||||
interpretCommandline();
|
interpretCommandline();
|
||||||
@@ -31,8 +31,8 @@ interpretCommandline();
|
|||||||
# datastring
|
# datastring
|
||||||
my @curves = ();
|
my @curves = ();
|
||||||
|
|
||||||
# list mapping curve names to their indices in the @curves list
|
# Maps a curve ID to the corresponding curve
|
||||||
my %curveIndices = ();
|
my %curveFromID = ();
|
||||||
|
|
||||||
# Whether any new data has arrived since the last replot
|
# Whether any new data has arrived since the last replot
|
||||||
my $haveNewData;
|
my $haveNewData;
|
||||||
@@ -90,8 +90,11 @@ sub interpretCommandline
|
|||||||
$options{legend} = [];
|
$options{legend} = [];
|
||||||
$options{curvestyle} = [];
|
$options{curvestyle} = [];
|
||||||
$options{style} = [];
|
$options{style} = [];
|
||||||
|
$options{every} = [];
|
||||||
$options{histogram} = [];
|
$options{histogram} = [];
|
||||||
$options{y2} = [];
|
$options{x1y2} = [];
|
||||||
|
$options{x2y1} = [];
|
||||||
|
$options{x2y2} = [];
|
||||||
$options{extracmds} = [];
|
$options{extracmds} = [];
|
||||||
$options{set} = [];
|
$options{set} = [];
|
||||||
$options{unset} = [];
|
$options{unset} = [];
|
||||||
@@ -102,18 +105,25 @@ sub interpretCommandline
|
|||||||
$options{with} = '';
|
$options{with} = '';
|
||||||
|
|
||||||
$options{rangesize} = [];
|
$options{rangesize} = [];
|
||||||
|
$options{tuplesize} = [];
|
||||||
|
|
||||||
GetOptions(\%options, 'stream:s', 'domain!', 'dataid!', '3d!', 'colormap!', 'lines!', 'points!',
|
GetOptions(\%options, 'stream:s', 'domain!', 'dataid!', 'vnlog!', '3d!', 'colormap!', 'lines!', 'points!',
|
||||||
'circles', 'legend=s{2}', 'autolegend!', 'xlabel=s', 'ylabel=s', 'y2label=s', 'zlabel=s',
|
'circles', 'legend=s{2}', 'autolegend!', 'xlabel=s', 'x2label=s', 'ylabel=s', 'y2label=s', 'zlabel=s',
|
||||||
'title=s', 'xlen=f', 'ymin=f', 'ymax=f', 'xmin=s', 'xmax=s', 'y2min=f', 'y2max=f',
|
'title=s', 'xlen=f',
|
||||||
'zmin=f', 'zmax=f', 'y2=s@',
|
'xmin=s', 'xmax=s', 'x2min=s', 'x2max=s',
|
||||||
|
'ymin=f', 'ymax=f', 'y2min=f', 'y2max=f',
|
||||||
|
'zmin=f', 'zmax=f',
|
||||||
|
'x2=s@', 'y2=s@', 'x1y2=s@', 'x2y1=s@', 'x2y2=s@',
|
||||||
'style=s{2}', 'curvestyle=s{2}', 'curvestyleall=s', 'styleall=s', 'with=s', 'extracmds=s@', 'set=s@', 'unset=s@',
|
'style=s{2}', 'curvestyle=s{2}', 'curvestyleall=s', 'styleall=s', 'with=s', 'extracmds=s@', 'set=s@', 'unset=s@',
|
||||||
'square!', 'square_xy!', 'hardcopy=s', 'maxcurves=i', 'monotonic!', 'timefmt=s',
|
'every=s{2}', 'everyall=s',
|
||||||
|
'square!', 'square_xy!', 'square-xy!', 'squarexy!', 'hardcopy=s', 'maxcurves=i', 'monotonic!', 'timefmt=s',
|
||||||
'equation=s@',
|
'equation=s@',
|
||||||
'image=s',
|
'image=s',
|
||||||
'histogram=s@', 'binwidth=f', 'histstyle=s',
|
'histogram=s@', 'binwidth=f', 'histstyle=s',
|
||||||
'terminal=s',
|
'terminal=s',
|
||||||
'rangesize=s{2}', 'rangesizeall=i', 'extraValuesPerPoint=i',
|
'rangesize=s{2}', 'rangesizeall=i',
|
||||||
|
'tuplesize=s{2}', 'tuplesizeall=i',
|
||||||
|
'extraValuesPerPoint=i', # deprecated and undocumented
|
||||||
'help', 'dump', 'exit', 'version',
|
'help', 'dump', 'exit', 'version',
|
||||||
'geometry=s') or exit 1;
|
'geometry=s') or exit 1;
|
||||||
|
|
||||||
@@ -140,6 +150,10 @@ sub interpretCommandline
|
|||||||
delete $options{styleall};
|
delete $options{styleall};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
# various square-xy synonyms
|
||||||
|
$options{'square_xy'} = 1 if $options{'square-xy'} || $options{'squarexy'};
|
||||||
|
|
||||||
|
|
||||||
push @{$options{curvestyle}}, @{$options{style}};
|
push @{$options{curvestyle}}, @{$options{style}};
|
||||||
delete $options{style};
|
delete $options{style};
|
||||||
|
|
||||||
@@ -154,14 +168,19 @@ sub interpretCommandline
|
|||||||
delete $options{with};
|
delete $options{with};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if( $options{dataid} && $options{vnlog} )
|
||||||
|
{
|
||||||
|
print STDERR "--dataid and --vnlog are mutually exclusive. Please just use one.\n";
|
||||||
|
exit -1;
|
||||||
|
}
|
||||||
|
|
||||||
# expand options that are given as comma-separated lists
|
# expand options that are given as comma-separated lists
|
||||||
for my $listkey (qw(histogram y2))
|
for my $listkey (qw(histogram x2 y2 x1y2 x2y1 x2y2))
|
||||||
{
|
{
|
||||||
@{$options{$listkey}} = map split('\s*,\s*', $_), @{$options{$listkey}}
|
@{$options{$listkey}} = map split('\s*,\s*', $_), @{$options{$listkey}}
|
||||||
if defined $options{$listkey};
|
if defined $options{$listkey};
|
||||||
}
|
}
|
||||||
for my $listkey (qw(curvestyle rangesize))
|
for my $listkey (qw(curvestyle rangesize tuplesize every))
|
||||||
{
|
{
|
||||||
next unless defined $options{$listkey};
|
next unless defined $options{$listkey};
|
||||||
my @in = @{$options{$listkey}};
|
my @in = @{$options{$listkey}};
|
||||||
@@ -180,6 +199,40 @@ sub interpretCommandline
|
|||||||
@{$options{$listkey}} = @out;
|
@{$options{$listkey}} = @out;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
# handle x2 == x2y1 and y2 == x1y2
|
||||||
|
push @{$options{x2y1}}, @{$options{x2}} if defined $options{x2};
|
||||||
|
push @{$options{x1y2}}, @{$options{y2}} if defined $options{y2};
|
||||||
|
$options{x2} = [];
|
||||||
|
$options{y2} = [];
|
||||||
|
|
||||||
|
# convert all tuplesize business to rangesize
|
||||||
|
my $domainsize = $options{'3d'} ? 2 : 1;
|
||||||
|
if (defined $options{tuplesizeall})
|
||||||
|
{
|
||||||
|
if (defined $options{rangesizeall} )
|
||||||
|
{
|
||||||
|
print STDERR "Only one of --rangesizeall and --tuplesizeall may be given\n";
|
||||||
|
exit -1;
|
||||||
|
}
|
||||||
|
|
||||||
|
$options{rangesizeall} = $options{tuplesizeall} - $domainsize;
|
||||||
|
delete $options{tuplesizeall};
|
||||||
|
}
|
||||||
|
if (defined $options{tuplesize})
|
||||||
|
{
|
||||||
|
$options{rangesize} //= [];
|
||||||
|
|
||||||
|
my $N = @{$options{tuplesize}} / 2;
|
||||||
|
for my $i (0..$N-1)
|
||||||
|
{
|
||||||
|
$options{tuplesize}[2*$i + 1] -= $domainsize;
|
||||||
|
}
|
||||||
|
|
||||||
|
push @{$options{rangesize}}, @{$options{tuplesize}};
|
||||||
|
delete $options{tuplesize};
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
# If we're plotting histograms, then set the default histogram options for
|
# If we're plotting histograms, then set the default histogram options for
|
||||||
# each histogram curve
|
# each histogram curve
|
||||||
@@ -202,7 +255,7 @@ sub interpretCommandline
|
|||||||
# arrays in order to preserve the ordering. I parse both of these into hashes
|
# arrays in order to preserve the ordering. I parse both of these into hashes
|
||||||
# because those are useful to have later. After this I can access individual
|
# because those are useful to have later. After this I can access individual
|
||||||
# legends with $options{legend_hash}{curveid}
|
# legends with $options{legend_hash}{curveid}
|
||||||
for my $listkey (qw(legend curvestyle rangesize))
|
for my $listkey (qw(legend curvestyle rangesize every))
|
||||||
{
|
{
|
||||||
$options{"${listkey}_hash"} = {};
|
$options{"${listkey}_hash"} = {};
|
||||||
|
|
||||||
@@ -310,9 +363,11 @@ sub interpretCommandline
|
|||||||
exit -1;
|
exit -1;
|
||||||
}
|
}
|
||||||
|
|
||||||
if ( defined $options{y2min} || defined $options{y2max} || @{$options{y2}} )
|
if ( defined $options{x2min} || defined $options{x2max} ||
|
||||||
|
defined $options{y2min} || defined $options{y2max} ||
|
||||||
|
@{$options{x1y2}} || @{$options{x2y1}} || @{$options{x2y2}} )
|
||||||
{
|
{
|
||||||
print STDERR "--3d does not make sense with --y2...\n";
|
print STDERR "--3d does not make sense with --x2... or --y2...\n";
|
||||||
exit -1;
|
exit -1;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -342,9 +397,9 @@ sub interpretCommandline
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
if ( $options{timefmt} && !$options{domain} )
|
if ( $options{timefmt} && !$options{domain} && !@{$options{histogram}} )
|
||||||
{
|
{
|
||||||
print STDERR "--timefmt makes sense only with --domain\n";
|
print STDERR "--timefmt makes sense only with --domain or --histogram\n";
|
||||||
exit -1;
|
exit -1;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -428,10 +483,13 @@ sub interpretCommandline
|
|||||||
{
|
{
|
||||||
# images generally have the origin at the top-left instead of the
|
# images generally have the origin at the top-left instead of the
|
||||||
# bottom-left, so given nothing else, I flip the y axis
|
# bottom-left, so given nothing else, I flip the y axis
|
||||||
if( !defined $options{ymin} && !defined $options{ymax} &&
|
if( !defined $options{xmin} && !defined $options{xmax} &&
|
||||||
|
!defined $options{ymin} && !defined $options{ymax} &&
|
||||||
|
! any { /^ *xrange\b/ } @{$options{set}} &&
|
||||||
! any { /^ *yrange\b/ } @{$options{set}} )
|
! any { /^ *yrange\b/ } @{$options{set}} )
|
||||||
{
|
{
|
||||||
push @{$options{set}}, "yrange [:] reverse";
|
push @{$options{set}}, "xrange [:] noextend";
|
||||||
|
push @{$options{set}}, "yrange [:] reverse noextend";
|
||||||
}
|
}
|
||||||
|
|
||||||
if ( ! -r $options{image} )
|
if ( ! -r $options{image} )
|
||||||
@@ -577,51 +635,15 @@ sub getNextLine
|
|||||||
sub mainThread
|
sub mainThread
|
||||||
{
|
{
|
||||||
local *PIPE;
|
local *PIPE;
|
||||||
my $dopersist = '';
|
|
||||||
|
|
||||||
if( getGnuplotVersion() >= 4.3 && # --persist not available before this
|
|
||||||
|
|
||||||
# --persist is needed for the "half-alive" state (see documentation for
|
|
||||||
# --exit). This state is only used with these options:
|
|
||||||
!$options{stream} && $options{exit})
|
|
||||||
{
|
|
||||||
$dopersist = '--persist';
|
|
||||||
}
|
|
||||||
|
|
||||||
# We trap SIGINT to kill the data input, but keep the plot up. see
|
|
||||||
# documentation for --exit
|
|
||||||
if ($options{stream} && !$options{exit})
|
|
||||||
{
|
|
||||||
$SIG{INT} = sub
|
|
||||||
{
|
|
||||||
print STDERR "$0 received SIGINT. Send again to quit\n";
|
|
||||||
$SIG{INT} = undef;
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
if(exists $options{dump})
|
|
||||||
{
|
|
||||||
*PIPE = *STDOUT;
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
my $geometry = defined $options{geometry} ?
|
|
||||||
"-geometry $options{geometry}" : '';
|
|
||||||
open PIPE, "|gnuplot $geometry $dopersist" or die "Can't initialize gnuplot\n";
|
|
||||||
}
|
|
||||||
autoflush PIPE 1;
|
|
||||||
|
|
||||||
my $outputfile;
|
my $outputfile;
|
||||||
my $outputfileType;
|
my $outputfileType;
|
||||||
if( defined $options{hardcopy})
|
if( defined $options{hardcopy})
|
||||||
{
|
{
|
||||||
$outputfile = $options{hardcopy};
|
$outputfile = $options{hardcopy};
|
||||||
if( $outputfile =~ /^[^|] # starts with anything other than |
|
if( $outputfile =~ /^[^|] # starts with anything other than |
|
||||||
.* # stuff in the middle
|
.* # stuff in the middle
|
||||||
\.(eps|ps|pdf|png|svg)$/ix) # ends with a known extension
|
\.(eps|ps|pdf|png|svg|gp)$/ix) # ends with a known extension
|
||||||
{
|
{
|
||||||
$outputfileType = lc $1;
|
$outputfileType = lc $1;
|
||||||
}
|
}
|
||||||
@@ -631,7 +653,8 @@ sub mainThread
|
|||||||
ps => 'postscript noenhanced solid color landscape 12',
|
ps => 'postscript noenhanced solid color landscape 12',
|
||||||
pdf => 'pdfcairo noenhanced solid color font ",12" size 11in,8.5in',
|
pdf => 'pdfcairo noenhanced solid color font ",12" size 11in,8.5in',
|
||||||
png => 'png noenhanced size 1280,1024',
|
png => 'png noenhanced size 1280,1024',
|
||||||
svg => 'svg noenhanced');
|
svg => 'svg noenhanced',
|
||||||
|
gp => 'gp');
|
||||||
|
|
||||||
if( !defined $options{terminal} &&
|
if( !defined $options{terminal} &&
|
||||||
defined $outputfileType &&
|
defined $outputfileType &&
|
||||||
@@ -643,8 +666,89 @@ sub mainThread
|
|||||||
die "Asked to plot to file '$outputfile', but I don't know which terminal to use, and no --terminal given"
|
die "Asked to plot to file '$outputfile', but I don't know which terminal to use, and no --terminal given"
|
||||||
unless $options{terminal};
|
unless $options{terminal};
|
||||||
}
|
}
|
||||||
print PIPE "set terminal $options{terminal}\n" if $options{terminal};
|
|
||||||
print PIPE "set output \"$outputfile\"\n" if $outputfile;
|
|
||||||
|
sub gpterminal
|
||||||
|
{
|
||||||
|
return defined $options{terminal} && $options{terminal} eq 'gp';
|
||||||
|
}
|
||||||
|
sub datadump_only
|
||||||
|
{
|
||||||
|
return
|
||||||
|
exists $options{dump} ||
|
||||||
|
gpterminal();
|
||||||
|
}
|
||||||
|
sub search_PATH
|
||||||
|
{
|
||||||
|
for my $pathdir (File::Spec->path())
|
||||||
|
{
|
||||||
|
my $gnuplot_execpath = File::Spec->catfile($pathdir, $_[0]);
|
||||||
|
return $gnuplot_execpath
|
||||||
|
if -x $gnuplot_execpath && ! -d $gnuplot_execpath;
|
||||||
|
}
|
||||||
|
return undef;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
if(datadump_only())
|
||||||
|
{
|
||||||
|
if(gpterminal())
|
||||||
|
{
|
||||||
|
open PIPE, '>', $outputfile;
|
||||||
|
|
||||||
|
my $gnuplotpath = search_PATH('gnuplot');
|
||||||
|
if(!defined $gnuplotpath)
|
||||||
|
{
|
||||||
|
print STDERR "Couldn't find the gnuplot executable path. Creating .gp file still, but omitting #!. This will NOT be self-executable";
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
chmod 0755, $outputfile;
|
||||||
|
print PIPE "#!$gnuplotpath\n";
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
*PIPE = *STDOUT;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
my $dopersist = '';
|
||||||
|
|
||||||
|
if ( getGnuplotVersion() >= 4.3 && # --persist not available before this
|
||||||
|
|
||||||
|
# --persist is needed for the "half-alive" state (see documentation for
|
||||||
|
# --exit). This state is only used with these options:
|
||||||
|
!$options{stream} && $options{exit}) {
|
||||||
|
$dopersist = '--persist';
|
||||||
|
}
|
||||||
|
|
||||||
|
# We trap SIGINT to kill the data input, but keep the plot up. see
|
||||||
|
# documentation for --exit
|
||||||
|
if ($options{stream} && !$options{exit})
|
||||||
|
{
|
||||||
|
$SIG{INT} = sub
|
||||||
|
{
|
||||||
|
print STDERR "$0 received SIGINT. Send again to quit\n";
|
||||||
|
$SIG{INT} = undef;
|
||||||
|
};
|
||||||
|
}
|
||||||
|
|
||||||
|
my $geometry = defined $options{geometry} ?
|
||||||
|
"-geometry $options{geometry}" : '';
|
||||||
|
open PIPE, "|gnuplot $geometry $dopersist" or die "Can't initialize gnuplot\n";
|
||||||
|
autoflush PIPE 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
if(!gpterminal())
|
||||||
|
{
|
||||||
|
print PIPE "set terminal $options{terminal}\n" if $options{terminal};
|
||||||
|
print PIPE "set output \"$outputfile\"\n" if $outputfile;
|
||||||
|
}
|
||||||
|
|
||||||
# set up plotting style
|
# set up plotting style
|
||||||
my $style = '';
|
my $style = '';
|
||||||
@@ -659,9 +763,10 @@ sub mainThread
|
|||||||
print PIPE "set grid\n";
|
print PIPE "set grid\n";
|
||||||
|
|
||||||
print(PIPE "set xlabel \"$options{xlabel }\"\n") if defined $options{xlabel};
|
print(PIPE "set xlabel \"$options{xlabel }\"\n") if defined $options{xlabel};
|
||||||
|
print(PIPE "set x2label \"$options{x2label}\"\n") if defined $options{x2label};
|
||||||
print(PIPE "set ylabel \"$options{ylabel }\"\n") if defined $options{ylabel};
|
print(PIPE "set ylabel \"$options{ylabel }\"\n") if defined $options{ylabel};
|
||||||
print(PIPE "set zlabel \"$options{zlabel }\"\n") if defined $options{zlabel};
|
|
||||||
print(PIPE "set y2label \"$options{y2label}\"\n") if defined $options{y2label};
|
print(PIPE "set y2label \"$options{y2label}\"\n") if defined $options{y2label};
|
||||||
|
print(PIPE "set zlabel \"$options{zlabel }\"\n") if defined $options{zlabel};
|
||||||
print(PIPE "set title \"$options{title }\"\n") if defined $options{title};
|
print(PIPE "set title \"$options{title }\"\n") if defined $options{title};
|
||||||
|
|
||||||
if($options{square})
|
if($options{square})
|
||||||
@@ -709,9 +814,21 @@ sub mainThread
|
|||||||
$options{curvestyle}[$idx*2 + 1]);
|
$options{curvestyle}[$idx*2 + 1]);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
if(@{$options{every}})
|
||||||
|
{
|
||||||
|
# @{$options{every}} is a list where consecutive pairs are (curveID,
|
||||||
|
# every).
|
||||||
|
my $n = scalar @{$options{every}}/2;
|
||||||
|
foreach my $idx (0..$n-1)
|
||||||
|
{
|
||||||
|
addEveryOption($options{every}[$idx*2 ],
|
||||||
|
$options{every}[$idx*2 + 1]);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
# For the values requested to be printed on the y2 axis, set that
|
addCurveOption($_, 'axes x1y2') foreach (@{$options{x1y2}});
|
||||||
addCurveOption($_, 'axes x1y2') foreach (@{$options{y2}});
|
addCurveOption($_, 'axes x2y1') foreach (@{$options{x2y1}});
|
||||||
|
addCurveOption($_, 'axes x2y2') foreach (@{$options{x2y2}});
|
||||||
|
|
||||||
# timefmt
|
# timefmt
|
||||||
if( $options{timefmt} )
|
if( $options{timefmt} )
|
||||||
@@ -728,7 +845,14 @@ sub mainThread
|
|||||||
|
|
||||||
setCurveAsHistogram( $_ ) foreach (@{$options{histogram}});
|
setCurveAsHistogram( $_ ) foreach (@{$options{histogram}});
|
||||||
|
|
||||||
if(@{$options{y2}})
|
if(@{$options{x2y1}} || @{$options{x2y2}})
|
||||||
|
{
|
||||||
|
print PIPE "set xtics nomirror\n";
|
||||||
|
print PIPE "set x2tics\n";
|
||||||
|
# if any of the ranges are given, set the range
|
||||||
|
sendRangeCommand( "x2range", $options{x2min}, $options{x2max} );
|
||||||
|
}
|
||||||
|
if(@{$options{x1y2}} || @{$options{x2y2}})
|
||||||
{
|
{
|
||||||
print PIPE "set ytics nomirror\n";
|
print PIPE "set ytics nomirror\n";
|
||||||
print PIPE "set y2tics\n";
|
print PIPE "set y2tics\n";
|
||||||
@@ -756,6 +880,41 @@ sub mainThread
|
|||||||
# The domain of the current point
|
# The domain of the current point
|
||||||
my @domain;
|
my @domain;
|
||||||
|
|
||||||
|
# column headers from vnlog
|
||||||
|
my @vnlog_headers;
|
||||||
|
if($options{vnlog})
|
||||||
|
{
|
||||||
|
require Vnlog::Parser;
|
||||||
|
require Vnlog::Util;
|
||||||
|
|
||||||
|
if ( !defined $pipe_in )
|
||||||
|
{
|
||||||
|
($pipe_in, $selector) = openNextFile();
|
||||||
|
}
|
||||||
|
|
||||||
|
my $parser = Vnlog::Parser->new();
|
||||||
|
while (defined ($_ = Vnlog::Util::get_unbuffered_line($pipe_in)))
|
||||||
|
{
|
||||||
|
if ( !$parser->parse($_) )
|
||||||
|
{
|
||||||
|
die "Error parsing vnlog: $parser->{error}; looking at line '$_'";
|
||||||
|
}
|
||||||
|
|
||||||
|
my $keys = $parser->getKeys();
|
||||||
|
if (defined $keys)
|
||||||
|
{
|
||||||
|
@vnlog_headers = @$keys;
|
||||||
|
last;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if(!@vnlog_headers)
|
||||||
|
{
|
||||||
|
die "Looked through all of the first file, and never saw a vnlog legend";
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
# The x-axis domain represented as a number. This is exactly the same as
|
# The x-axis domain represented as a number. This is exactly the same as
|
||||||
# $domain[0] unless the x-axis domain uses a timefmt. Then this is the
|
# $domain[0] unless the x-axis domain uses a timefmt. Then this is the
|
||||||
# number of seconds since the UNIX epoch.
|
# number of seconds since the UNIX epoch.
|
||||||
@@ -793,6 +952,7 @@ sub mainThread
|
|||||||
# 3d plots require $options{domain}, and dictate "x y" for the domain instead of just "x"
|
# 3d plots require $options{domain}, and dictate "x y" for the domain instead of just "x"
|
||||||
|
|
||||||
my @fields = split;
|
my @fields = split;
|
||||||
|
my $i_column = 0;
|
||||||
|
|
||||||
if($options{domain})
|
if($options{domain})
|
||||||
{
|
{
|
||||||
@@ -804,6 +964,7 @@ sub mainThread
|
|||||||
|
|
||||||
$domain[0] = join (' ', splice( @fields, 0, $options{timefmt_Ncols}) );
|
$domain[0] = join (' ', splice( @fields, 0, $options{timefmt_Ncols}) );
|
||||||
$domain0_numeric = makeDomainNumeric( $domain[0] );
|
$domain0_numeric = makeDomainNumeric( $domain[0] );
|
||||||
|
$i_column += $options{timefmt_Ncols};
|
||||||
}
|
}
|
||||||
elsif(!$options{'3d'})
|
elsif(!$options{'3d'})
|
||||||
{
|
{
|
||||||
@@ -812,6 +973,7 @@ sub mainThread
|
|||||||
next if @fields < 1+1;
|
next if @fields < 1+1;
|
||||||
|
|
||||||
$domain[0] = $domain0_numeric = shift @fields;
|
$domain[0] = $domain0_numeric = shift @fields;
|
||||||
|
$i_column += 1;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
@@ -820,6 +982,7 @@ sub mainThread
|
|||||||
next if @fields < 2+1;
|
next if @fields < 2+1;
|
||||||
|
|
||||||
@domain = splice(@fields, 0, 2);
|
@domain = splice(@fields, 0, 2);
|
||||||
|
$i_column += 2;
|
||||||
}
|
}
|
||||||
|
|
||||||
if( $options{monotonic} )
|
if( $options{monotonic} )
|
||||||
@@ -839,16 +1002,32 @@ sub mainThread
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
$domain[0] = $line_number;
|
$domain[0] = $line_number;
|
||||||
$domain0_numeric = makeDomainNumeric( $domain[0] );
|
$domain0_numeric = $line_number;
|
||||||
}
|
}
|
||||||
|
|
||||||
my $id = -1;
|
my $id = -1;
|
||||||
|
|
||||||
while(@fields)
|
while(@fields)
|
||||||
{
|
{
|
||||||
if($options{dataid}) { $id = shift @fields; }
|
if ($options{dataid})
|
||||||
else { $id++; }
|
{
|
||||||
|
$id = shift @fields;
|
||||||
|
}
|
||||||
|
elsif($options{vnlog} )
|
||||||
|
{
|
||||||
|
if( $i_column >= @vnlog_headers )
|
||||||
|
{
|
||||||
|
# Got more columns than vnlog headers. The data is probably
|
||||||
|
# bogus, but I don't want to barf at the user, so I silently
|
||||||
|
# ignore the data
|
||||||
|
last;
|
||||||
|
}
|
||||||
|
$id = $vnlog_headers[$i_column];
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
$id++;
|
||||||
|
}
|
||||||
|
|
||||||
my $rangesize = getRangeSize($id);
|
my $rangesize = getRangeSize($id);
|
||||||
last if @fields < $rangesize;
|
last if @fields < $rangesize;
|
||||||
@@ -858,13 +1037,15 @@ sub mainThread
|
|||||||
@domain,
|
@domain,
|
||||||
splice( @fields, 0, $rangesize ) ) . "\n",
|
splice( @fields, 0, $rangesize ) ) . "\n",
|
||||||
$domain0_numeric);
|
$domain0_numeric);
|
||||||
|
|
||||||
|
$i_column += $rangesize;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
# finished reading in all. Plot what we have
|
# finished reading in all. Plot what we have
|
||||||
plotStoredData() unless $options{stream} && $options{exit};
|
plotStoredData() unless $options{stream} && $options{exit};
|
||||||
|
|
||||||
if ( defined $options{hardcopy})
|
if ( defined $options{hardcopy} && !gpterminal())
|
||||||
{
|
{
|
||||||
print PIPE "set output\n";
|
print PIPE "set output\n";
|
||||||
|
|
||||||
@@ -893,7 +1074,15 @@ sub mainThread
|
|||||||
# we persist gnuplot, so we shouldn't need this sleep. However, once
|
# we persist gnuplot, so we shouldn't need this sleep. However, once
|
||||||
# gnuplot exits, but the persistent window sticks around, you can no
|
# gnuplot exits, but the persistent window sticks around, you can no
|
||||||
# longer interactively zoom the plot. So we still sleep
|
# longer interactively zoom the plot. So we still sleep
|
||||||
sleep(100000000) unless $options{dump} || $options{exit};
|
if(gpterminal())
|
||||||
|
{
|
||||||
|
print PIPE "pause mouse close\n";
|
||||||
|
close PIPE;
|
||||||
|
}
|
||||||
|
elsif(!($options{dump} || $options{exit}))
|
||||||
|
{
|
||||||
|
print PIPE "pause mouse close\n";
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
sub pruneOldData
|
sub pruneOldData
|
||||||
@@ -967,7 +1156,7 @@ sub updateCurveOptions
|
|||||||
my $histoptions = $curve->{histoptions} || '';
|
my $histoptions = $curve->{histoptions} || '';
|
||||||
|
|
||||||
my $usingoptions = '';
|
my $usingoptions = '';
|
||||||
if( $options{timefmt} )
|
if( $options{timefmt} && !$histoptions )
|
||||||
{
|
{
|
||||||
# with --timefmt I need an explicit 'using' specification. I specify the
|
# with --timefmt I need an explicit 'using' specification. I specify the
|
||||||
# columns as 1:2:3..... I need the right number of columns (this is given
|
# columns as 1:2:3..... I need the right number of columns (this is given
|
||||||
@@ -980,7 +1169,7 @@ sub updateCurveOptions
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
$curve->{options} = "$histoptions $usingoptions $titleoption $curve->{extraoptions}";
|
$curve->{options} = "$curve->{everyoptions} $histoptions $usingoptions $titleoption $curve->{extraoptions}";
|
||||||
}
|
}
|
||||||
|
|
||||||
sub getCurve
|
sub getCurve
|
||||||
@@ -997,19 +1186,20 @@ sub getCurve
|
|||||||
|
|
||||||
my ($id) = @_;
|
my ($id) = @_;
|
||||||
|
|
||||||
if( !exists $curveIndices{$id} )
|
if( !exists $curveFromID{$id} )
|
||||||
{
|
{
|
||||||
push @curves, {# if we have a catch-all style and no specific style, use
|
my $curve = {extraoptions => ( exists $options{curvestyleall}) ?
|
||||||
# the catch-all style
|
"$options{curvestyleall} " : ' ',
|
||||||
extraoptions => (!exists $options{curvestyle_hash}{$id} &&
|
everyoptions => (!exists $options{every_hash}{$id} &&
|
||||||
exists $options{curvestyleall}) ?
|
exists $options{everyall}) ?
|
||||||
"$options{curvestyleall} " : ' ',
|
"every $options{everyall} " : ' ',
|
||||||
datastring => '',
|
datastring => '',
|
||||||
datastring_meta => [],
|
datastring_meta => [],
|
||||||
datastring_offset => 0}; # push a curve with no data and no options
|
datastring_offset => 0}; # push a curve with no data and no options
|
||||||
$curveIndices{$id} = $#curves;
|
push @curves, $curve; # push a curve with no data and no options
|
||||||
|
$curveFromID{$id} = $curve;
|
||||||
|
|
||||||
updateCurveOptions($curves[$#curves], $id);
|
updateCurveOptions($curve, $id);
|
||||||
|
|
||||||
|
|
||||||
# --xlen has a meaning if we're not plotting histograms at all or if we're
|
# --xlen has a meaning if we're not plotting histograms at all or if we're
|
||||||
@@ -1026,8 +1216,11 @@ sub getCurve
|
|||||||
print STDERR "--xlen only makes sense when plotting ONLY histograms or ONLY NON-histograms\n";
|
print STDERR "--xlen only makes sense when plotting ONLY histograms or ONLY NON-histograms\n";
|
||||||
exit -1;
|
exit -1;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
return $curve;
|
||||||
}
|
}
|
||||||
return $curves[$curveIndices{$id}];
|
|
||||||
|
return $curveFromID{$id};
|
||||||
}
|
}
|
||||||
|
|
||||||
sub addCurveOption
|
sub addCurveOption
|
||||||
@@ -1038,6 +1231,14 @@ sub addCurveOption
|
|||||||
$curve->{extraoptions} .= "$str ";
|
$curve->{extraoptions} .= "$str ";
|
||||||
updateCurveOptions($curve, $id);
|
updateCurveOptions($curve, $id);
|
||||||
}
|
}
|
||||||
|
sub addEveryOption
|
||||||
|
{
|
||||||
|
my ($id, $str) = @_;
|
||||||
|
|
||||||
|
my $curve = getCurve($id);
|
||||||
|
$curve->{everyoptions} .= "every $str ";
|
||||||
|
updateCurveOptions($curve, $id);
|
||||||
|
}
|
||||||
|
|
||||||
sub setCurveLabel
|
sub setCurveLabel
|
||||||
{
|
{
|
||||||
@@ -1173,47 +1374,48 @@ Simple plotting of piped data:
|
|||||||
|
|
||||||
$ seq 5 | awk '{print 2*$1, $1*$1}' |
|
$ seq 5 | awk '{print 2*$1, $1*$1}' |
|
||||||
feedgnuplot --lines --points --legend 0 "data 0" --title "Test plot" --y2 1
|
feedgnuplot --lines --points --legend 0 "data 0" --title "Test plot" --y2 1
|
||||||
--terminal 'dumb 80,40' --exit
|
--unset grid --terminal 'dumb 80,40' --exit
|
||||||
|
|
||||||
Test plot
|
Test plot
|
||||||
|
|
||||||
10 ++------+--------+-------+-------+-------+--------+-------+------*A 25
|
10 +-----------------------------------------------------------------+ 25
|
||||||
+ + + + + + + + **#+
|
| + + + + + + + *##|
|
||||||
| : : : : : : data 0+**A*** |
|
| data 0 ***A*#* |
|
||||||
| : : : : : : :** # |
|
| ** # |
|
||||||
9 ++.......................................................**.##....|
|
9 |-+ ** ## |
|
||||||
| : : : : : : ** :# |
|
| ** # |
|
||||||
| : : : : : : ** # |
|
| ** # |
|
||||||
| : : : : : :** ##: ++ 20
|
| ** ## +-| 20
|
||||||
8 ++................................................A....#..........|
|
8 |-+ A # |
|
||||||
| : : : : : **: # : |
|
| ** # |
|
||||||
| : : : : : ** : ## : |
|
| ** ## |
|
||||||
| : : : : : ** :# : |
|
| ** # |
|
||||||
| : : : : :** B : |
|
| ** B |
|
||||||
7 ++......................................**......##................|
|
7 |-+ ** ## |
|
||||||
| : : : : ** : ## : : ++ 15
|
| ** ## +-| 15
|
||||||
| : : : : ** : # : : |
|
| ** # |
|
||||||
| : : : :** : ## : : |
|
| ** ## |
|
||||||
6 ++..............................*A.......##.......................|
|
6 |-+ *A ## |
|
||||||
| : : : ** : ##: : : |
|
| ** ## |
|
||||||
| : : : ** : # : : : |
|
| ** # |
|
||||||
| : : :** : ## : : : ++ 10
|
| ** ## +-| 10
|
||||||
5 ++......................**........##..............................|
|
5 |-+ ** ## |
|
||||||
| : : ** : #B : : : |
|
| ** #B |
|
||||||
| : : ** : ## : : : : |
|
| ** ## |
|
||||||
| : :** : ## : : : : |
|
| ** ## |
|
||||||
4 ++...............A.......###......................................|
|
4 |-+ A ### |
|
||||||
| : **: ##: : : : : |
|
| ** ## |
|
||||||
| : ** : ## : : : : : ++ 5
|
| ** ## +-| 5
|
||||||
| : ** : ## : : : : : |
|
| ** ## |
|
||||||
| :** ##B# : : : : : |
|
| ** ##B# |
|
||||||
3 ++.....**..####...................................................|
|
3 |-+ ** #### |
|
||||||
| **#### : : : : : : |
|
| **#### |
|
||||||
| **## : : : : : : : |
|
| #### |
|
||||||
B** + + + + + + + +
|
|## + + + + + + + |
|
||||||
2 A+------+--------+-------+-------+-------+--------+-------+------++ 0
|
2 +-----------------------------------------------------------------+ 0
|
||||||
1 1.5 2 2.5 3 3.5 4 4.5 5
|
1 1.5 2 2.5 3 3.5 4 4.5 5
|
||||||
|
|
||||||
|
Here we asked for ASCII plotting, which is useful for documentation.
|
||||||
|
|
||||||
Simple real-time plotting example: plot how much data is received on the wlan0
|
Simple real-time plotting example: plot how much data is received on the wlan0
|
||||||
network interface in bytes/second (uses bash, awk and Linux):
|
network interface in bytes/second (uses bash, awk and Linux):
|
||||||
@@ -1279,41 +1481,64 @@ with the I<X>-value at the start of that line.
|
|||||||
|
|
||||||
=head3 Curve indexing
|
=head3 Curve indexing
|
||||||
|
|
||||||
By default, each column represents a separate curve. This is fine unless sparse
|
We index the curves in one of 3 ways: sequentially, explicitly with a
|
||||||
data is to be plotted. With the C<--dataid> option, each point is represented by
|
C<--dataid> or by C<--vnlog> headers.
|
||||||
2 values: a string identifying the curve, and the value itself. If we add
|
|
||||||
C<--dataid> to the original example:
|
By default, each column represents a separate curve. The first column (after any
|
||||||
|
domain) is curve C<0>. The next one is curve C<1> and so on. This is fine unless
|
||||||
|
sparse data is to be plotted. With the C<--dataid> option, each point is
|
||||||
|
represented by 2 values: a string identifying the curve, and the value itself.
|
||||||
|
If we add C<--dataid> to the original example:
|
||||||
|
|
||||||
$ seq 5 | awk '{print 2*$1, $1*$1}' | feedgnuplot --dataid --autolegend
|
$ seq 5 | awk '{print 2*$1, $1*$1}' | feedgnuplot --dataid --autolegend
|
||||||
|
|
||||||
we get 5 different curves with one point in each. The first column, as produced
|
we get 5 different curves with one point in each. The first column, as produced
|
||||||
by C<awk>, is B<2,4,6,8,10>. These are interpreted as the IDs of the curves to
|
by C<awk>, is B<2,4,6,8,10>. These are interpreted as the IDs of the curves to
|
||||||
be plotted. The C<--autolegend> option adds a legend using the given IDs to
|
be plotted.
|
||||||
|
|
||||||
|
If we're plotting C<vnlog> data (L<https://www.github.com/dkogan/vnlog>) then we
|
||||||
|
can get the curve IDs from the vnlog header. Vnlog is a trivial data format
|
||||||
|
where lines starting with C<#> are comments and the first comment contains
|
||||||
|
column labels. If we have such data, C<feedgnuplot --vnlog> can interpret these
|
||||||
|
column labels if the C<vnlog> perl modules are available.
|
||||||
|
|
||||||
|
The C<--autolegend> option adds a legend using the given IDs to
|
||||||
label the curves. The IDs need not be numbers; generic strings are accepted. As
|
label the curves. The IDs need not be numbers; generic strings are accepted. As
|
||||||
many points as desired can appear on a single line. C<--domain> can be used in
|
many points as desired can appear on a single line. C<--domain> can be used in
|
||||||
conjunction with C<--dataid>.
|
conjunction with C<--dataid> or C<--vnlog>.
|
||||||
|
|
||||||
=head3 Multi-value style support
|
=head3 Multi-value style support
|
||||||
|
|
||||||
Depending on how gnuplot is plotting the data, more than one value may be needed
|
Depending on how gnuplot is plotting the data, more than one value may be needed
|
||||||
to represent the range of a single point. Basic 2D plots have 2 numbers
|
to represent the range of a single point. Basic 2D plots have 2 numbers
|
||||||
representing each point: 1 domain and 1 range. But if plotting with
|
representing each point: 1 domain and 1 range. But if plotting with
|
||||||
C<--circles>, for instance, then there's an extra range value: the radius. A
|
C<--circles>, for instance, then there's an extra range value: the radius. Many
|
||||||
similar situation exists with C<--colormap> where each point contains the
|
other gnuplot styles require more data: errorbars, variable colors (C<with
|
||||||
position I<and> the color. There are other gnuplot styles that require more data
|
points palette>), variable sizes (C<with points ps variable>), labels and so on.
|
||||||
(such as error bars), but none of these are directly supported by the script.
|
The feedgnuplot tool itself does not know about all these intricacies, but they
|
||||||
They can still be used, however, by specifying the specific style with
|
can still be used, by specifying the specific style with C<--style>, and
|
||||||
C<--style>, and specifying how many values are needed for each point with
|
specifying how many values are needed for each point with any of
|
||||||
C<--rangesizeall> or C<--rangesize> or C<--extraValuesPerPoint>. Those options
|
C<--rangesizeall>, C<--tuplesizeall>, C<--rangesize>, C<--tuplesize>. These
|
||||||
that specify the range size are required I<only> for styles not explicitly
|
options are required I<only> for styles not explicitly supported by feedgnuplot;
|
||||||
supported by feedgnuplot; supported styles do the right thing automatically.
|
supported styles do the right thing automatically.
|
||||||
|
|
||||||
More examples: if making a 2d plot of y error bars where gnuplot expects a
|
Specific example: if making a 2d plot of y error bars, the exact format can be
|
||||||
(x,y,ydelta) tuple for each point, you want C<--rangesizeall 2> because you have
|
queried by running C<gnuplot> and invoking C<help yerrorbars>. This tells us
|
||||||
one domain value (x) and 2 range values (y,ydelta). Gnuplot can also plot
|
that there's a 3-column form: C<x y ydelta> and a 4-column form: C<x y ylow
|
||||||
lopsided y errorbars by giving a tuple (x,y,ylow,yhigh). This is similar as
|
yhigh>. With 2d plots feedgnuplot will always output the 1-value domain C<x>, so
|
||||||
before, but you want C<--rangesizeall 3> instead.
|
the rangesize is 2 and 3 respectively. Thus the following are equivalent:
|
||||||
|
|
||||||
|
$ echo '1 2 0.3
|
||||||
|
2 3 0.4
|
||||||
|
3 4 0.5' | feedgnuplot --domain --rangesizeall 2 --with 'yerrorbars'
|
||||||
|
|
||||||
|
$ echo '1 2 0.3
|
||||||
|
2 3 0.4
|
||||||
|
3 4 0.5' | feedgnuplot --domain --tuplesizeall 3 --with 'yerrorbars'
|
||||||
|
|
||||||
|
$ echo '1 2 1.7 2.3
|
||||||
|
2 3 2.6 3.4
|
||||||
|
3 4 3.5 4.5' | feedgnuplot --domain --rangesizeall 3 --with 'yerrorbars'
|
||||||
|
|
||||||
=head3 3D data
|
=head3 3D data
|
||||||
|
|
||||||
@@ -1417,15 +1642,20 @@ This command causes feedgnuplot to exit.
|
|||||||
|
|
||||||
The script is able to produce hardcopy output with C<--hardcopy outputfile>. The
|
The script is able to produce hardcopy output with C<--hardcopy outputfile>. The
|
||||||
output type can be inferred from the filename, if B<.ps>, B<.eps>, B<.pdf>,
|
output type can be inferred from the filename, if B<.ps>, B<.eps>, B<.pdf>,
|
||||||
B<.svg> or B<.png> is requested. If any other file type is requested,
|
B<.svg>, B<.png> or B<.gp> is requested. If any other file type is requested,
|
||||||
C<--terminal> I<must> be passed in to tell gnuplot how to make the plot. If
|
C<--terminal> I<must> be passed in to tell gnuplot how to make the plot. If
|
||||||
C<--terminal> is passed in, then the C<--hardcopy> argument only provides the
|
C<--terminal> is passed in, then the C<--hardcopy> argument only provides the
|
||||||
output filename.
|
output filename.
|
||||||
|
|
||||||
|
The B<.gp> output is special. Instead of asking gnuplot to plot to a particular
|
||||||
|
terminal, writing to a B<.gp> simply dumps a self-executable gnuplot script into
|
||||||
|
the given file. This is similar to what C<--dump> does, but writes to a file,
|
||||||
|
and makes sure that the file can be self-executing.
|
||||||
|
|
||||||
=head2 Self-plotting data files
|
=head2 Self-plotting data files
|
||||||
|
|
||||||
This script can be used to enable self-plotting data files. There are 2 ways of
|
This script can be used to enable self-plotting data files. There are several
|
||||||
doing this: with a shebang (#!) or with inline perl data.
|
ways of doing this: with a shebang (#!) or with inline perl data.
|
||||||
|
|
||||||
=head3 Self-plotting data with a #!
|
=head3 Self-plotting data with a #!
|
||||||
|
|
||||||
@@ -1459,6 +1689,11 @@ characters and that the full path to feedgnuplot must be given. The 127
|
|||||||
character limit is a serious limitation, but this can likely be resolved with a
|
character limit is a serious limitation, but this can likely be resolved with a
|
||||||
kernel patch. I have only tried on Linux 2.6.
|
kernel patch. I have only tried on Linux 2.6.
|
||||||
|
|
||||||
|
=head3 Self-plotting data with gnuplot
|
||||||
|
|
||||||
|
Running C<feedgnuplot --hardcopy plotdata.gp ....> will create a self-executable
|
||||||
|
gnuplot script in C<plotdata.gp>
|
||||||
|
|
||||||
=head3 Self-plotting data with perl inline data
|
=head3 Self-plotting data with perl inline data
|
||||||
|
|
||||||
Perl supports storing data and code in the same file. This can also be used to
|
Perl supports storing data and code in the same file. This can also be used to
|
||||||
@@ -1547,6 +1782,19 @@ point in curve ID 20
|
|||||||
|
|
||||||
=item
|
=item
|
||||||
|
|
||||||
|
C<--vnlog>
|
||||||
|
|
||||||
|
Vnlog is a trivial data format where lines starting with C<#> are comments and
|
||||||
|
the first comment contains column labels. Some tools for working with such data
|
||||||
|
are available from the C<vnlog> project: L<https://www.github.com/dkogan/vnlog>.
|
||||||
|
With the C<vnlog> perl modules installed, we can read the vnlog column headers
|
||||||
|
with C<feedgnuplot --vnlog>. This replaces C<--dataid>, and we can do all the
|
||||||
|
normal things with these headers. For instance C<feedgnuplot --vnlog
|
||||||
|
--autolegend> will generate plot legends for each column in the vnlog, using the
|
||||||
|
vnlog column label in the legend.
|
||||||
|
|
||||||
|
=item
|
||||||
|
|
||||||
C<--[no]3d>
|
C<--[no]3d>
|
||||||
|
|
||||||
Do [not] plot in 3D. This only makes sense with C<--domain>. Each domain here is
|
Do [not] plot in 3D. This only makes sense with C<--domain>. Each domain here is
|
||||||
@@ -1563,7 +1811,8 @@ Interpret the X data as a time/date, parsed with the given format
|
|||||||
C<--colormap>
|
C<--colormap>
|
||||||
|
|
||||||
Show a colormapped xy plot. Requires extra data for the color. zmin/zmax can be
|
Show a colormapped xy plot. Requires extra data for the color. zmin/zmax can be
|
||||||
used to set the extents of the colors. Automatically sets the C<--rangesize>.
|
used to set the extents of the colors. Automatically sets the
|
||||||
|
C<--rangesize>/C<--tuplesize>.
|
||||||
|
|
||||||
=item
|
=item
|
||||||
|
|
||||||
@@ -1591,7 +1840,8 @@ Do [not] draw points
|
|||||||
C<--circles>
|
C<--circles>
|
||||||
|
|
||||||
Plot with circles. This requires a radius be specified for each point.
|
Plot with circles. This requires a radius be specified for each point.
|
||||||
Automatically sets the C<--rangesize>. C<Not> supported for 3d plots.
|
Automatically sets the C<--rangesize>/C<--tuplesize>. C<Not> supported for 3d
|
||||||
|
plots.
|
||||||
|
|
||||||
=item
|
=item
|
||||||
|
|
||||||
@@ -1628,31 +1878,40 @@ plot I<only> histograms or I<only> I<non>-histograms.
|
|||||||
|
|
||||||
=item
|
=item
|
||||||
|
|
||||||
C<--xmin/xmax/ymin/ymax/y2min/y2max/zmin/zmax xxx>
|
C<--xmin/xmax/x2min/x2max/ymin/ymax/y2min/y2max/zmin/zmax xxx>
|
||||||
|
|
||||||
Set the range for the given axis. These x-axis bounds are ignored in a streaming
|
Set the range for the given axis. These x-axis bounds are ignored in a streaming
|
||||||
plot. The y2-axis bound do not apply in 3d plots. The z-axis bounds apply
|
plot. The x2/y2-axis bounds do not apply in 3d plots. The z-axis bounds apply
|
||||||
I<only> to 3d plots or colormaps.
|
I<only> to 3d plots or colormaps. Note that there is no C<--xrange> to set both
|
||||||
|
sides at once or C<--xinv> to flip the axis around: anything more than the
|
||||||
|
basics supported in this option is clearly obtainable by talking to gnuplot, for
|
||||||
|
instance C<--set 'xrange [20:10]'> to set the given inverted bounds.
|
||||||
|
|
||||||
=item
|
=item
|
||||||
|
|
||||||
C<--xlabel/ylabel/y2label/zlabel xxx>
|
C<--xlabel/x2label/ylabel/y2label/zlabel xxx>
|
||||||
|
|
||||||
Label the given axis. The y2-axis label does not apply to 3d plots while the
|
Label the given axis. The x2/y2-axis labels do not apply to 3d plots while the
|
||||||
z-axis label applies I<only> to 3d plots.
|
z-axis label applies I<only> to 3d plots.
|
||||||
|
|
||||||
=item
|
=item
|
||||||
|
|
||||||
C<--y2 xxx>
|
C<--x2/--y2/--x1y2/--x2y1/--x2y2 xxx>
|
||||||
|
|
||||||
Plot the data specified by this curve ID on the y2 axis. Without C<--dataid>,
|
By default data is plotted against the x1 and y1 axes (the left and bottom one
|
||||||
the ID is just an ordered 0-based index. Does not apply to 3d plots. Can be
|
respectively). If we want a particular curve plotted against a different axis,
|
||||||
passed multiple times, or passed a comma-separated list. By default the y2-axis
|
we can specify that with these options. You pass C<--AXIS ID> where C<AXIS>
|
||||||
curves look the same as the y-axis ones. I.e. the viewer of the resulting plot
|
defines the axis (C<x2> or C<y2> or C<x1y2> or C<x2y1> or C<x2y2>) and the C<ID>
|
||||||
has to be told which is which via an axes label, legend, etc. Prior to version
|
is the curve ID. C<--x2> is a synonym for C<--x2y1> and C<--y2> is a synonym for
|
||||||
1.25 of feedgnuplot the curves plotted on the y2 axis were drawn with a thicker
|
C<--x1y2>. The curve ID is an ordered 0-based index or a specific ID if
|
||||||
line. This is no longer the case, but that behavior can be brought back by
|
C<--dataid> or C<--vnlog>. None of these apply to 3d plots. Can be passed
|
||||||
passing something like
|
multiple times for different curve IDs, multiple IDs can be passed in as a
|
||||||
|
comma-separated list. By default the curves plotted against the various axes
|
||||||
|
aren not drawn in any differentiated way: the viewer of the resulting plot has
|
||||||
|
to be told which is which via an axes label, legend, colors, etc. Prior to
|
||||||
|
version 1.25 of C<feedgnuplot> the curves plotted on the y2 axis were drawn with
|
||||||
|
a thicker line. This is no longer the case, but that behavior can be brought
|
||||||
|
back by passing something like
|
||||||
|
|
||||||
--y2 curveid --style curveid 'linewidth 3'
|
--y2 curveid --style curveid 'linewidth 3'
|
||||||
|
|
||||||
@@ -1735,6 +1994,21 @@ Exclusive with C<--styleall>.
|
|||||||
|
|
||||||
=item
|
=item
|
||||||
|
|
||||||
|
C<--every curveID factor>
|
||||||
|
|
||||||
|
Decimates the input. Instead of plotting every point in the given curve, plot
|
||||||
|
one point per factor. This is useful to quickly process huge datasets. For
|
||||||
|
instance, to plot 1% of the data, pass a factor of 100.
|
||||||
|
|
||||||
|
=item
|
||||||
|
|
||||||
|
C<--everyallID factor>
|
||||||
|
|
||||||
|
Decimates the input. This works exactly like C<--every>, except it applies to
|
||||||
|
I<all> the curves.
|
||||||
|
|
||||||
|
=item
|
||||||
|
|
||||||
C<--extracmds xxx>
|
C<--extracmds xxx>
|
||||||
|
|
||||||
Additional commands to pass on to gnuplot verbatim. These could contain extra
|
Additional commands to pass on to gnuplot verbatim. These could contain extra
|
||||||
@@ -1774,9 +2048,9 @@ Gnuplot can plot both data and symbolic equations. C<feedgnuplot> generally
|
|||||||
plots data, but with this option can plot symbolic equations I<also>. This is
|
plots data, but with this option can plot symbolic equations I<also>. This is
|
||||||
generally intended to augment data plots, since for equation-only plots you
|
generally intended to augment data plots, since for equation-only plots you
|
||||||
don't need C<feedgnuplot>. C<--equation> can be passed multiple times for
|
don't need C<feedgnuplot>. C<--equation> can be passed multiple times for
|
||||||
multiple equations. The given strings are passed to gnuplot directly without any
|
multiple equations. The given strings are passed to gnuplot directly without
|
||||||
thing added or removed, so styling and such should be applied in the string. A
|
anything added or removed, so styling and such should be applied in the string.
|
||||||
basic example:
|
A basic example:
|
||||||
|
|
||||||
seq 100 | awk '{print $1/10, $1/100}' |
|
seq 100 | awk '{print $1/10, $1/100}' |
|
||||||
feedgnuplot --with 'lines lw 3' --domain --ymax 1
|
feedgnuplot --with 'lines lw 3' --domain --ymax 1
|
||||||
@@ -1803,7 +2077,7 @@ all 3 axes
|
|||||||
|
|
||||||
=item
|
=item
|
||||||
|
|
||||||
C<--square_xy>
|
C<--square-xy>
|
||||||
|
|
||||||
For 3D plots, set square aspect ratio for ONLY the x,y axes
|
For 3D plots, set square aspect ratio for ONLY the x,y axes
|
||||||
|
|
||||||
@@ -1826,7 +2100,7 @@ file type is desired, use both C<--hardcopy> and C<--terminal>
|
|||||||
|
|
||||||
=item
|
=item
|
||||||
|
|
||||||
C<--maxcurves xxx>
|
C<--maxcurves N>
|
||||||
|
|
||||||
The maximum allowed number of curves. This is 100 by default, but can be reset
|
The maximum allowed number of curves. This is 100 by default, but can be reset
|
||||||
with this option. This exists purely to prevent perl from allocating all of the
|
with this option. This exists purely to prevent perl from allocating all of the
|
||||||
@@ -1836,20 +2110,22 @@ system's memory when reading bogus data
|
|||||||
|
|
||||||
C<--monotonic>
|
C<--monotonic>
|
||||||
|
|
||||||
If C<--domain> is given, checks to make sure that the x- coordinate in the input
|
If C<--domain> is given, checks to make sure that the x-coordinate in the input
|
||||||
data is monotonically increasing. If a given x-variable is in the past, all data
|
data is monotonically increasing. If a given x-variable is in the past, all data
|
||||||
currently cached for this curve is purged. Without C<--monotonic>, all data is
|
currently cached for this curve is purged. Without C<--monotonic>, all data is
|
||||||
kept. Does not make sense with 3d plots. No C<--monotonic> by default. The data is
|
kept. Does not make sense with 3d plots. No C<--monotonic> by default. The data
|
||||||
replotted before being purged
|
is replotted before being purged. This is useful in streaming plots where the
|
||||||
|
incoming data represents multiple iterations of the same process (repeated
|
||||||
|
simulations of the same period in time, for instance).
|
||||||
|
|
||||||
=item
|
=item
|
||||||
|
|
||||||
C<--rangesize curveID xxx>
|
C<--rangesize curveID N>
|
||||||
|
|
||||||
The options C<--rangesizeall>, C<--rangesize> and C<--extraValuesPerPoint> set
|
The options C<--rangesizeall> and C<--rangesize> set the number of values are
|
||||||
the number of values are needed to represent each point being plotted (see
|
needed to represent each point being plotted (see L</"Multi-value style
|
||||||
L</"Multi-value style support"> above). These options are I<only> needed if
|
support"> above). These options are I<only> needed if unknown styles are used,
|
||||||
unknown styles are used, with C<--styleall> or C<--with> for instance.
|
with C<--styleall> or C<--with> for instance.
|
||||||
|
|
||||||
C<--rangesize> is used to set how many values are needed to represent the range
|
C<--rangesize> is used to set how many values are needed to represent the range
|
||||||
of a point for a particular curve. This overrides any defaults that may exist
|
of a point for a particular curve. This overrides any defaults that may exist
|
||||||
@@ -1861,19 +2137,25 @@ rangesize should apply.
|
|||||||
|
|
||||||
=item
|
=item
|
||||||
|
|
||||||
C<--rangesizeall xxx>
|
C<--tuplesize curveID N>
|
||||||
|
|
||||||
|
Very similar to C<--rangesize>, but instead of specifying the I<range> only,
|
||||||
|
this specifies the whole tuple. For instance if we're plotting circles, the
|
||||||
|
tuplesize is 3: C<x,y,radius>. In a 2D plot there's a 1-dimensional domain:
|
||||||
|
C<x>, so the rangesize is 2: C<y,radius>. This dimensionality can be given
|
||||||
|
either way.
|
||||||
|
|
||||||
|
=item
|
||||||
|
|
||||||
|
C<--rangesizeall N>
|
||||||
|
|
||||||
Like C<--rangesize>, but applies to I<all> the curves.
|
Like C<--rangesize>, but applies to I<all> the curves.
|
||||||
|
|
||||||
C<--extraValuesPerPoint xxx>
|
=item
|
||||||
|
|
||||||
Like C<--rangesizeall>, but instead of overriding the default, adds to it. For
|
C<--tuplesizeall N>
|
||||||
example, if plotting non-lopsided y errorbars gnuplot wants (x,y,ydelta) tuples.
|
|
||||||
These can be specified both with C<--rangesizeall 2> (because there are 2 range
|
|
||||||
values) or C<--extraValuesPerPoint 1> (because there's 1 more value than usual).
|
|
||||||
|
|
||||||
This option is I<only> needed if unknown styles are used, with C<--styleall> or
|
Like C<--tuplesize>, but applies to I<all> the curves.
|
||||||
C<--with> for instance.
|
|
||||||
|
|
||||||
=item
|
=item
|
||||||
|
|
||||||
|
@@ -9,6 +9,8 @@ complete -W \
|
|||||||
--curvestyleall \
|
--curvestyleall \
|
||||||
--style \
|
--style \
|
||||||
--styleall \
|
--styleall \
|
||||||
|
--every \
|
||||||
|
--everyall \
|
||||||
--with \
|
--with \
|
||||||
--dataid \
|
--dataid \
|
||||||
--domain \
|
--domain \
|
||||||
@@ -17,6 +19,8 @@ complete -W \
|
|||||||
--extraValuesPerPoint \
|
--extraValuesPerPoint \
|
||||||
--rangesizeall \
|
--rangesizeall \
|
||||||
--rangesize \
|
--rangesize \
|
||||||
|
--tuplesizeall \
|
||||||
|
--tuplesize \
|
||||||
--extracmds \
|
--extracmds \
|
||||||
--set \
|
--set \
|
||||||
--unset \
|
--unset \
|
||||||
@@ -33,23 +37,31 @@ complete -W \
|
|||||||
--monotonic \
|
--monotonic \
|
||||||
--points \
|
--points \
|
||||||
--square \
|
--square \
|
||||||
--square_xy \
|
--square-xy \
|
||||||
--stream \
|
--stream \
|
||||||
--terminal \
|
--terminal \
|
||||||
--timefmt \
|
--timefmt \
|
||||||
--title \
|
--title \
|
||||||
--version \
|
--version \
|
||||||
|
--x2 \
|
||||||
|
--y2 \
|
||||||
|
--x2y1 \
|
||||||
|
--x1y2 \
|
||||||
|
--x2y2 \
|
||||||
--xlabel \
|
--xlabel \
|
||||||
--xlen \
|
--xlen \
|
||||||
--xmax \
|
--xmax \
|
||||||
--xmin \
|
--xmin \
|
||||||
--y2 \
|
--x2label \
|
||||||
--y2label \
|
--x2max \
|
||||||
--y2max \
|
--x2min \
|
||||||
--y2min \
|
|
||||||
--ylabel \
|
--ylabel \
|
||||||
--ymax \
|
--ymax \
|
||||||
--ymin \
|
--ymin \
|
||||||
|
--y2label \
|
||||||
|
--y2max \
|
||||||
|
--y2min \
|
||||||
--zlabel \
|
--zlabel \
|
||||||
--zmax \
|
--zmax \
|
||||||
--zmin' feedgnuplot
|
--zmin \
|
||||||
|
--vnlog ' feedgnuplot
|
||||||
|
@@ -10,22 +10,28 @@ _arguments -S
|
|||||||
'--points' \
|
'--points' \
|
||||||
'--circles' \
|
'--circles' \
|
||||||
'--xlabel:X-axis label:' \
|
'--xlabel:X-axis label:' \
|
||||||
|
'--x2label:X2-axis label:' \
|
||||||
'--ylabel:Y-axis label:' \
|
'--ylabel:Y-axis label:' \
|
||||||
'--y2label:Y2-axis label:' \
|
'--y2label:Y2-axis label:' \
|
||||||
'--zlabel:Z-axis label:' \
|
'--zlabel:Z-axis label:' \
|
||||||
'--zlabel:Z-axis label:' \
|
|
||||||
'--title:Plot title:' \
|
'--title:Plot title:' \
|
||||||
'--autolegend[Label each plot with its data ID]' \
|
'--autolegend[Label each plot with its data ID]' \
|
||||||
'(--3d)--xlen[the size of the x-window to plot]::window size:' \
|
'(--3d)--xlen[the size of the x-window to plot]:window size:' \
|
||||||
'(--xlen)--xmin:min X:' \
|
'(--xlen)--xmin:min X:' \
|
||||||
'(--xlen)--xmax:max X:' \
|
'(--xlen)--xmax:max X:' \
|
||||||
|
'--x2min:min X2:' \
|
||||||
|
'--x2max:max X2:' \
|
||||||
'--ymin:min Y:' \
|
'--ymin:min Y:' \
|
||||||
'--ymax:max Y:' \
|
'--ymax:max Y:' \
|
||||||
'--y2min:min Y2:' \
|
'--y2min:min Y2:' \
|
||||||
'--y2max:max Y2:' \
|
'--y2max:max Y2:' \
|
||||||
'--zmin:min Z:' \
|
'--zmin:min Z:' \
|
||||||
'--zmax:max Z:' \
|
'--zmax:max Z:' \
|
||||||
'*--y2:plot to place on the Y2 axis:' \
|
'*--x2:curve to place on the X2Y1 axis:' \
|
||||||
|
'*--y2:curve to place on the X1Y2 axis:' \
|
||||||
|
'*--x2y1:curve to place on the X2Y1 axis:' \
|
||||||
|
'*--x1y2:curve to place on the X1Y2 axis:' \
|
||||||
|
'*--x2y2:curve to place on the X2Y2 axis:' \
|
||||||
'(--with)--curvestyleall[Additional styles for ALL curves]:style' \
|
'(--with)--curvestyleall[Additional styles for ALL curves]:style' \
|
||||||
'(--with)--styleall[Additional styles for ALL curves]:style' \
|
'(--with)--styleall[Additional styles for ALL curves]:style' \
|
||||||
'(--curvestyleall)--with[Additional styles for ALL curves]:style' \
|
'(--curvestyleall)--with[Additional styles for ALL curves]:style' \
|
||||||
@@ -35,23 +41,28 @@ _arguments -S
|
|||||||
'*--equation[Raw symbolic equation]:equation' \
|
'*--equation[Raw symbolic equation]:equation' \
|
||||||
'--image[Image file to render beneath the data]:image:_files -g "(#i)*.(jpg|jpeg|png|gif)"' \
|
'--image[Image file to render beneath the data]:image:_files -g "(#i)*.(jpg|jpeg|png|gif)"' \
|
||||||
'--square[Plot data with square aspect ratio]' \
|
'--square[Plot data with square aspect ratio]' \
|
||||||
'--square_xy[For 3D plots, set square aspect ratio for ONLY the x,y axes]' \
|
'--square-xy[For 3D plots, set square aspect ratio for ONLY the x,y axes]' \
|
||||||
'--hardcopy[Plot to a file]:new image filename:_files -g "(#i)*.(jpg|jpeg|png|gif)"' \
|
'--hardcopy[Plot to a file]:new image filename:_files -g "(#i)*.(jpg|jpeg|png|gif)"' \
|
||||||
'--maxcurves[The maximum allowed number of curves]:number of curves' \
|
'--maxcurves[The maximum allowed number of curves]:number of curves' \
|
||||||
'(--3d)--monotonic[Resets plot if an X in the past is seen]' \
|
'(--3d)--monotonic[Resets plot if an X in the past is seen]' \
|
||||||
'(--rangesizeall)--extraValuesPerPoint[How many extra values are given for each data range]:N'\
|
'(--rangesizeall)--extraValuesPerPoint[How many extra values are given for each data range]:N'\
|
||||||
'(--extraValuesPerPoint)--rangesizeall[How many values are given for each data range]:N'\
|
'(--extraValuesPerPoint)--rangesizeall[How many values are given for each data range]:N'\
|
||||||
'*--rangesize[How many values comprise a data range in this curve]:curve id: :N:' \
|
'*--rangesize[How many values comprise a data range in this curve]:curve id: :N:' \
|
||||||
|
'(--extraValuesPerPoint)--tuplesizeall[How many values are given for each data tuple]:N'\
|
||||||
|
'*--tuplesize[How many values comprise a data tuple in this curve]:curve id: :N:' \
|
||||||
'--dump[Instead of printing to gnuplot, print to STDOUT]' \
|
'--dump[Instead of printing to gnuplot, print to STDOUT]' \
|
||||||
'--geometry[The X11 geometry string]:geometry string:' \
|
'--geometry[The X11 geometry string]:geometry string:' \
|
||||||
'*--curvestyle[Additional styles for a curve]:curve id: :style:' \
|
'*--curvestyle[Additional styles for a curve]:curve id: :style:' \
|
||||||
'*--style[Additional styles for a curve]:curve id: :style:' \
|
'*--style[Additional styles for a curve]:curve id: :style:' \
|
||||||
|
'*--every[Decimation factor for a curve]:curve id: :decimation factor:' \
|
||||||
|
'--everyall[Decimation factor for ALL curves]:decimation factor' \
|
||||||
'(--3d)*--histogram:plot to treat as a histogram:' \
|
'(--3d)*--histogram:plot to treat as a histogram:' \
|
||||||
'--binwidth:Histogram bin width:' \
|
'--binwidth:Histogram bin width:' \
|
||||||
'--histstyle:Style of histogram:(frequency unique cumulative cnormal)' \
|
'--histstyle:Style of histogram:(frequency fnormal unique cumulative cnormal)' \
|
||||||
'--terminal:Terminal options to set with "set terminal":' \
|
'--terminal:Terminal options to set with "set terminal":' \
|
||||||
'*--legend[Legend for a curve]:curve id: :legend:' \
|
'*--legend[Legend for a curve]:curve id: :legend:' \
|
||||||
'--exit[Exit gnuplot after making the plot]' \
|
'--exit[Exit gnuplot after making the plot]' \
|
||||||
'--version' \
|
'--version' \
|
||||||
'--help' \
|
'--help' \
|
||||||
'--timefmt[Format for time/date data]:time format'
|
'--timefmt[Format for time/date data]:time format' \
|
||||||
|
'--vnlog[column IDs come from a vnlog header]'
|
||||||
|
64
debian/changelog
vendored
64
debian/changelog
vendored
@@ -1,3 +1,67 @@
|
|||||||
|
feedgnuplot (1.54-1) unstable; urgency=medium
|
||||||
|
|
||||||
|
* New upstream release
|
||||||
|
- Added --every and --everyall to decimate the input data
|
||||||
|
- --timefmt can be used with --histogram
|
||||||
|
|
||||||
|
-- Dima Kogan <dkogan@debian.org> Fri, 17 Apr 2020 14:21:07 -0700
|
||||||
|
|
||||||
|
feedgnuplot (1.53-1) unstable; urgency=medium
|
||||||
|
|
||||||
|
* New upstream release
|
||||||
|
- Full support for all 4 axes. Added --x2...
|
||||||
|
|
||||||
|
-- Dima Kogan <dkogan@debian.org> Wed, 08 Jan 2020 18:59:29 -0800
|
||||||
|
|
||||||
|
feedgnuplot (1.52-1) unstable; urgency=medium
|
||||||
|
|
||||||
|
[ Jelmer Vernooij ]
|
||||||
|
* Use secure copyright file specification URI.
|
||||||
|
* Trim trailing whitespace.
|
||||||
|
|
||||||
|
[ Dima Kogan ]
|
||||||
|
* New upstream release
|
||||||
|
- --square-xy and --squarexy as synonyms for --square_xy
|
||||||
|
|
||||||
|
-- Dima Kogan <dkogan@debian.org> Sun, 25 Aug 2019 15:34:56 -0700
|
||||||
|
|
||||||
|
feedgnuplot (1.51-1) unstable; urgency=medium
|
||||||
|
|
||||||
|
* Added .gp "terminal" to create self-plotting gnuplot files
|
||||||
|
|
||||||
|
-- Dima Kogan <dkogan@debian.org> Sat, 29 Sep 2018 11:00:40 -0700
|
||||||
|
|
||||||
|
feedgnuplot (1.50-1) unstable; urgency=medium
|
||||||
|
|
||||||
|
* Script waits for the plot window to close before exiting
|
||||||
|
Instead of sleeping forever. This is really nice! I no longer need
|
||||||
|
to quit the plot window AND then C-c. Quitting the plot window is
|
||||||
|
now sufficient
|
||||||
|
* by default --image sets range noextend
|
||||||
|
* tab-completion knows about the fnormal distribution
|
||||||
|
|
||||||
|
-- Dima Kogan <dkogan@debian.org> Fri, 24 Aug 2018 13:16:35 -0700
|
||||||
|
|
||||||
|
feedgnuplot (1.49-2) unstable; urgency=medium
|
||||||
|
|
||||||
|
* Updated Vcs-... tags to salsa
|
||||||
|
|
||||||
|
-- Dima Kogan <dkogan@debian.org> Sun, 17 Jun 2018 22:18:18 -0700
|
||||||
|
|
||||||
|
feedgnuplot (1.49-1) unstable; urgency=medium
|
||||||
|
|
||||||
|
* --vnl now works with plots that have rangesize > 1
|
||||||
|
* zsh completion: --xlen argument isn't optional
|
||||||
|
|
||||||
|
-- Dima Kogan <dkogan@debian.org> Fri, 16 Mar 2018 13:56:27 -0700
|
||||||
|
|
||||||
|
feedgnuplot (1.48-1) unstable; urgency=medium
|
||||||
|
|
||||||
|
* Added --tuplesize and --tuplesizeall
|
||||||
|
* vnlog integration
|
||||||
|
|
||||||
|
-- Dima Kogan <dkogan@debian.org> Sat, 24 Feb 2018 12:56:05 -0800
|
||||||
|
|
||||||
feedgnuplot (1.45-1) unstable; urgency=medium
|
feedgnuplot (1.45-1) unstable; urgency=medium
|
||||||
|
|
||||||
* zsh completion: --hardcopy, --image suggest filenames
|
* zsh completion: --hardcopy, --image suggest filenames
|
||||||
|
7
debian/control
vendored
7
debian/control
vendored
@@ -3,17 +3,18 @@ Section: science
|
|||||||
Priority: optional
|
Priority: optional
|
||||||
Build-Depends: debhelper (>= 9), libstring-shellquote-perl, perl, gawk, gnuplot, libipc-run-perl
|
Build-Depends: debhelper (>= 9), libstring-shellquote-perl, perl, gawk, gnuplot, libipc-run-perl
|
||||||
Maintainer: Debian Science Maintainers <debian-science-maintainers@lists.alioth.debian.org>
|
Maintainer: Debian Science Maintainers <debian-science-maintainers@lists.alioth.debian.org>
|
||||||
Uploaders: Dima Kogan <dima@secretsauce.net>
|
Uploaders: Dima Kogan <dkogan@debian.org>
|
||||||
Standards-Version: 3.9.4
|
Standards-Version: 3.9.4
|
||||||
Homepage: https://github.com/dkogan/feedgnuplot
|
Homepage: https://github.com/dkogan/feedgnuplot
|
||||||
Vcs-Git: git://anonscm.debian.org/debian-science/packages/feedgnuplot.git
|
Vcs-Browser: https://salsa.debian.org/science-team/feedgnuplot
|
||||||
Vcs-Browser: http://anonscm.debian.org/gitweb/?p=debian-science/packages/feedgnuplot.git
|
Vcs-Git: https://salsa.debian.org/science-team/feedgnuplot.git
|
||||||
|
|
||||||
Package: feedgnuplot
|
Package: feedgnuplot
|
||||||
Architecture: all
|
Architecture: all
|
||||||
Depends: ${misc:Depends}, ${perl:Depends},
|
Depends: ${misc:Depends}, ${perl:Depends},
|
||||||
liblist-moreutils-perl,
|
liblist-moreutils-perl,
|
||||||
gnuplot-qt | gnuplot-x11 | gnuplot-nox | gnuplot5-qt | gnuplot5-x11 | gnuplot5-nox | gnuplot
|
gnuplot-qt | gnuplot-x11 | gnuplot-nox | gnuplot5-qt | gnuplot5-x11 | gnuplot5-nox | gnuplot
|
||||||
|
Suggests: vnlog
|
||||||
Description: Pipe-oriented frontend to Gnuplot
|
Description: Pipe-oriented frontend to Gnuplot
|
||||||
Flexible, command-line-oriented frontend to Gnuplot. Creates plots from data
|
Flexible, command-line-oriented frontend to Gnuplot. Creates plots from data
|
||||||
coming in on STDIN or given in a filename passed on the commandline. Various
|
coming in on STDIN or given in a filename passed on the commandline. Various
|
||||||
|
2
debian/copyright
vendored
2
debian/copyright
vendored
@@ -1,4 +1,4 @@
|
|||||||
Format: http://www.debian.org/doc/packaging-manuals/copyright-format/1.0/
|
Format: https://www.debian.org/doc/packaging-manuals/copyright-format/1.0/
|
||||||
Source: https://github.com/dkogan/feedgnuplot
|
Source: https://github.com/dkogan/feedgnuplot
|
||||||
Upstream-Contact: Dima Kogan, <dima@secretsauce.net>
|
Upstream-Contact: Dima Kogan, <dima@secretsauce.net>
|
||||||
Upstream-Name: feedgnuplot
|
Upstream-Name: feedgnuplot
|
||||||
|
2
debian/feedgnuplot.install
vendored
2
debian/feedgnuplot.install
vendored
@@ -1,2 +1,2 @@
|
|||||||
completions/bash/feedgnuplot /etc/bash_completion.d/
|
completions/bash/feedgnuplot /usr/share/bash-completion/completions/
|
||||||
completions/zsh/_feedgnuplot /usr/share/zsh/vendor-completions
|
completions/zsh/_feedgnuplot /usr/share/zsh/vendor-completions
|
||||||
|
Reference in New Issue
Block a user