开发者

How to present a plot and then return to cmd prompt

开发者 https://www.devze.com 2022-12-30 01:13 出处:网络
I have a data file, and a gnu file, in which my plotting commands are. How can I produce a plot in gnuplot, in a way that I call gnuplot giving it a name开发者_JAVA百科 of the gnu file ... it gives m

I have a data file, and a gnu file, in which my plotting commands are.

How can I produce a plot in gnuplot, in a way that I call gnuplot giving it a name开发者_JAVA百科 of the gnu file ... it gives me the window with a plot ... and after I close it, it returns me not to gnuplot command prompt, but to cmd (windows cmd.exe) command prompt ?


There's 3 solutions for this problem (for producing persistent plots) when starting gnuplot from a script (using gnuplot script.gnuplot).

  • Use a pause -1 at the end of your gnuplot script (after the plot), such that a user needs to press enter before gnuplot destroys the window with the plot
  • Use gnuplot script.gnuplot - to go into gnuplot's interactive mode after the script has completed
  • Use the -persist command line option to create a persistent plot window
0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号