|
From: Daniel J S. <dan...@ie...> - 2006-04-02 08:15:12
|
Daniel J Sebald wrote: > Chris, > > I've read your list entry and will investigate. I can't recall thinking > to try an example with multiple plots and "-", so there may be a problem. Actually, I did give an example of this. If you look in 'image.dem' there is a plot titled: "Binary data specified at the command line, intended for use through pipe" in which the binary data is inside the file itself (i.e., as though one somehow typed binary data at the command line, which will never happen but it is simply meant to illustrate). So... >> plot "-" binary record=5x2 using 1:2 with linespoints,\ >> "-" binary record=5x2 using 1:2 with linespoints >> >> cat "command-2.gp" "binary.dat" "binary.dat" | gnuplot >> >> The error message seems to indicated the second "-" is the problem: >> >> gnuplot> plot "-" binary record=5x2 using 1:($2) with linespoints, >> "-" >> binary record=5x2 using 1:($2)**2 with linespoints >> >> ^ >> line 0: warning: Skipping data file with no valid points >> ... I wonder why the above is failing. The warning makes me think that gnuplot believes it has run out of data. Might you have an extra CR or LF as a result of the cat process? Actually, this seems to work for me. For example, try the attached files with the command cat "command" "bin1.bin" "bin2.bin" | gnuplot and you should see a PNG file appear in the directory. >> The documentation page explains that: >> >> >>> General binary data can be entered at the command line via >> >> >> the special file name '-'. However, this is intended for use through >> a pipe where programs can exchange binary data, not for keyboards. >> There is no "end of record" character for binary data. >> Gnuplot continues reading from a pipe until it has read the >> number of points declared in the array qualifier. >> >> But I used a record qualifier. And I don't know how to simulate the >> array using >> records (even given that I can resort the order of the binary data). >> Both >> "array=5,5 index0" and "array=5,5 index 1" work like I expect. But I >> don't see >> how i can make an (x,y) plot from index 0 and index 1. >> >> Can gnuplot do the same ascii data tricks with binary data? I'm not exactly sure what you mean to do here. However, look through the examples in image.dem and see if there is anything close to what you want. (I'm thinking there should be.) I tried giving enough examples of every feature. Dan |