help-octave
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: synchronization of octave with gnuplot?


From: Thorsten Meyer
Subject: Re: synchronization of octave with gnuplot?
Date: Fri, 03 Dec 2004 18:48:58 +0100
User-agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.7.3) Gecko/20041007 Debian/1.7.3-5

Thanks a lot!

That's the solution!

John W. Eaton wrote:

On  2-Dec-2004, Mike Miller <address@hidden> wrote:

| On Thu, 2 Dec 2004, Thorsten Meyer wrote:
| | >> It is possible to put an 'if' statement in your script to have it | >> either "sleep(1)" or execute the awk code depending on the existence of | >> a file or the existence of an ending element in a file tail. | > | > You are right. I could have octave wait for the existence of the file. | > But as soon as it exists, I would have to keep parsing it in a loop in | > order to see if it is complete. | | But can't you then use my second suggestion and look at the file tail for | a string? For example, maybe this command... | | tail -1 file.eps | | ...always returns this string... | | %%EOF | | ...when the gnuplot process has completed. The details of how this would | be done depend on your shell.

If you just want to postprocess, then why not write your awk script as
a filter, then do something like

 gset output "| awk -f myscript.awk > foo.eps"

Does that work?  To get the output flushed to the pipe, you may have
to issue another "gset output" command or use closeplot.

jwe





-------------------------------------------------------------
Octave is freely available under the terms of the GNU GPL.

Octave's home on the web:  http://www.octave.org
How to fund new projects:  http://www.octave.org/funding.html
Subscription information:  http://www.octave.org/archive.html
-------------------------------------------------------------



reply via email to

[Prev in Thread] Current Thread [Next in Thread]