i have fortran 90 program outputs data .txt file. data plotted gnuplot.
i able launch gnuplot with
call system("start wgnuplot")
which equivalent type
start gnuplot
in windows command line prompt.
but then, have program telling gnuplot next, i.e., changing directory right one, , plotting file.txt.
all in boils down simpler question:
how pass command line in windows launches gnuplot , gives additional commands?
i tried easier plotting y=x. in normal gnuplot windows plot x.
from cmd.exe (which called fortran's call system() )i've tried:
start wgnuplot plot x start wgnuplot plot x -pause start wgnuplot plot x -persist start wgnuplot plot x -noend start wgnuplot plot x /noend
and others, including every possible variant or without quotation marks, instance
start wgnuplot "plot x -persist"
etc.
so far 1 works basic
start gnuplot
which starts gnuplot indeed. don't know how add next commands. once have working command line input believe have plop call system argument have fortran program doing work.
i find instructions on how achieve on unix-like machine, not on windows. appreciated.
background info: windows 8, code::blocks, gnuplot 5.0 patchlevel 1
you need use named pipes easy in c , unix:
http://tldp.org/ldp/lpg/node11.html , see answer: https://stackoverflow.com/a/14027358/2743307
in fortran , unix can use shell mkfifo
command: https://genomeek.wordpress.com/2012/05/07/tips-reading-compressed-file-with-fortran-and-named-pipe/
Comments
Post a Comment