Sponsored Content
Full Discussion: xargs and gnuplot
Top Forums Shell Programming and Scripting xargs and gnuplot Post 302354775 by paulianna2002 on Saturday 19th of September 2009 06:03:23 PM
Old 09-19-2009
xargs and gnuplot

Hi All,

Seems I have an xargs stdin problem that I don't understand.

I have a script (call it myscript.sh) that takes the names of one or more file(s) specified on the command line and creates a single gnuplot command file containing multiple records, one for each specified file. Each of those records is terminated by a gnuplot "pause -1" command that suspends execution until the user presses the enter key. Sort of like this:

gnuplot commands for first .dat file
pause -1


gnuplot commands for second .dat file
pause -1

etc,etc,etc

If I run 'myscript.sh file1.dat file2.dat', it works as expected and gnuplot waits for me to press the enter key before moving onto the next plot.

But, if I do something like 'ls file*.dat | xargs myscript.sh' gnuplot runs through all of the plots without waiting for me to press enter.

So, gnuplot is getting something from stdin effectively making my pause commands useless.

Any ideas would be greatly appreciated.

Thanks in advance.
 

9 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

Help with gnuplot

Hi, I am a beginner using UNIX, and was wondering how to use gnuplot from UNIX on my pc. I am connected remotely to my work's UNIX server using Secure Shell Client, and gnuplot won't open a new window when I use the plot command. How do I do this? Moreover, is it possible to save things from the... (0 Replies)
Discussion started by: KTTFB64
0 Replies

2. UNIX and Linux Applications

gnuplot + 3-d grids

When designing a 3-d graph in gnuplot, is it possible to create a 3-d grid that goes through each point on the graph ? (0 Replies)
Discussion started by: JamesGoh
0 Replies

3. AIX

Sarcheck - gnuplot 3.7.1

Good Afternoon, I'm having an issue finding the correct libX11.a fileset on my 595 running AIX 5.3.0.0. Currently I'm trying to instal Sarcheck on my nim master. The problem occurs during the GNUPLOT installation. error: failed dependencies: libX11.a(shr4.o) is needed by gnuplot-3.7.1-1... (3 Replies)
Discussion started by: vincent1117
3 Replies

4. UNIX and Linux Applications

GNUplot

Hi, I am trying to make a plot of an ASCII file using GNUplot, but I keep getting error msg: for example plot filename.txt It says that (.txt ) is not identified ... I tried to write it without the .txt part, but I also get the error msg. Any idea why? :confused: (1 Reply)
Discussion started by: cosmologist
1 Replies

5. UNIX and Linux Applications

gnuplot limitations

I'm running a simulation (programmed in C) which makes calls to gnuplot periodically to plot data I have stored. First I open a pipe to gnuplot and set it to multiplot: FILE * pipe = popen("gnuplot", "w"); fprintf(pipe, "set multiplot\n"); fflush(pipe); (this pipe stays open until the... (0 Replies)
Discussion started by: sedavidw
0 Replies

6. UNIX for Dummies Questions & Answers

GNUPLOT problem

Hi, Im trying to plot a time series with gnuplot. this is my script set xdata time set yrange set timefmt "%H" set xrange set format x "%H:%M:%S" plot "time_vs_times.txt" using 1:2 title 'Interarrival time' with points lw 2 and this is my data 11:14:18 5 11:14:19 10... (10 Replies)
Discussion started by: jamie_123
10 Replies

7. Shell Programming and Scripting

Gnuplot command

My data input looks like this: -16.25 -38.75 9.69094 -16.25 -36.25 10.0594 -16.25 -33.75 10.3884 -16.25 -31.25 10.6653 -16.25 -28.75 10.7947 -16.25 -26.25 10.8838 -16.25 -23.75 10.8463 -16.25 -21.25 10.8131 -16.25 -18.75 10.7509 -16.25 -16.25 10.6581 -16.25 -13.75 10.6859 -16.25... (0 Replies)
Discussion started by: programmerc
0 Replies

8. Shell Programming and Scripting

Gnuplot in bash

Hi, I want a graph plot using gnuplot for df -h command. like filesystem, total size and avail size. Thanks, Anjan ---------- Post updated at 02:35 PM ---------- Previous update was at 02:34 PM ---------- I want a graph plot using gnuplot for df -h command per hour. (4 Replies)
Discussion started by: Anjan1
4 Replies

9. Shell Programming and Scripting

Gnuplot question

Hi! Let's say I have these two columns in file.txt 0 1 1 5 2 10 3 15 4 20 5 25 in gnuplot, i would plot usingplot 'file.txt' u 1:2 If I wanted to add a label to the y-axis I would useset label "Ef" at 0.0,7.0 However, I want the label Ef to be on the otherside of the y-axis. Not... (0 Replies)
Discussion started by: sidiq1983
0 Replies
PLOTCHANGELOG(1)					      General Commands Manual						  PLOTCHANGELOG(1)

NAME
plotchangelog - graph debian changelogs SYNOPSIS
plotchangelog [options] changelog ... DESCRIPTION
plotchangelog is a tool to aid in visualizing a Debian changelog. The changelogs are graphed with gnuplot(1) , with the X axis of the graph denoting time of release and the Y axis denoting the debian version number of the package. Each individual release of the package is repre- sented by a point, and the points are color coded to indicate who released that version of the package. The upstream version number of the package can also be labeled on the graph. Alternatively, the Y axis can be configured to display the size of the changelog entry for each new version. Or it can be configured to display approximately how many bugs were fixed for each new version. Note that if the package is a debian-specific package, the entire package version will be used for the Y axis. This does not always work perfectly. READING THE GRAPH
The general outline of a package's graph is typically a series of peaks, starting at 1, going up to n, and then returning abruptly to 1. The higher the peaks, the more releases the maintainer made between new upstream versions of the package. If a package is debian-only, it's graph will just grow upwards without ever falling (although a bug in this program may cause it to fall sometimes, if the version number goes from say, 0.9 to say, 0.10 - this is interpreted wrong..) If the graph dips below 1, someone made a NMU of the package and upgraded it to a new upstream version, thus setting the debian version to 0. NMU's in general appear as fractional points like 1.1, 2.1, etc. A NMU can also be easily detected by looking at the points that repre- sent which maintainer uploaded the package -- a solitary point of a different type than the points before and after it is typically a NMU. It's also easy to tell by looking at the points when a package changes maintainers. OPTIONS
-l, --linecount Instead of using the debian version number as the Y axis, use the number of lines in the changelog entry for each version. Cannot be used together with --bugcount. -b, --bugcount Instead of using the debian version number as the Y axis, use the number of bugs that were closed by each changelog entry. Note that this number is obtained by searching for "#dddd" in the changelog, and so it may be inaccurate. Cannot be used together with --linecount. -c, --cumulative When used together with either --bugcount or --linecount, graphs the cumulative count rather than the count in each individual changelog entry. -v, --no-version Do not show upstream version labels. Useful if the graph gets too crowded. -m, --no-maint Do not differentiate between different maintainers of the package. -s file, --save=file Save the graph to file in postscript format instead of immediately displaying it. -u, --urgency Use larger points when displaying higher-urgency package uploads. --verbose Output the gnuplot script that is fed into gnuplot (for debugging purposes). -gcommands, --gnuplot=commands This allows you to insert gnuplot(1) commands into the gnuplot script that is used to generate the graph. The commands are placed after all initialization but before the final plot command. This can be used to override the default look provided by this program in arbitrary ways. You can also use things like "set terminal png color" to change the output file type, which is useful in conjunc- tion with the -s option. --help Show a usage summary. --version Display version, author and copyright information. --noconf, --no-conf Do not read any configuration files (see below). changelog ... The changelog files to graph. If multiple files are specified they will all be display on the same graph. The files may be com- pressed with gzip. Any text in them that is not in Debian changelog format will be ignored. CONFIGURATION VARIABLES
The two configuration files /etc/devscripts.conf and ~/.devscripts are sourced by a shell in that order to set configuration variables. The --no-conf option can be used to prevent reading these files. Environment variable settings are ignored when these configuration files are read. The currently recognised variables are: PLOTCHANGELOG_OPTIONS This is a space-separated list of options to always use, for example -l -b. Do not include -g or --gnuplot among this list as it may be ignored; see the next variable instead. PLOTCHANGELOG_GNUPLOT These are gnuplot commands which will be prepended to any such commands given on the command line. SEE ALSO
devscripts.conf(5). AUTHOR
Joey Hess <joey@kitenet.net> DEBIAN
Debian Utilities PLOTCHANGELOG(1)
All times are GMT -4. The time now is 12:26 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy