macros - Gnuplot: How to "forget" last plot and replotting only things inside an iteration -
macros - Gnuplot: How to "forget" last plot and replotting only things inside an iteration -
i'm plotting functions generated during iteration. i'm using gnuplot 4.4 loop done loading file , rereading multiple times.
plot sin(x) = 0 set macros plot 0 # <==== don't load "plotting_iteration" unset macros where "plotting_iteration" like:
i = + 1 fstr = sprintf("a%d*x+b%d*sqrt(x-1)+c%d", monthn,monthn,monthn) replot @fstr if (i < 6) reread; replot updates lastly plot "new plots", need way leave "sin(x)" out. way found forget first "plot sin(x)" "plot 0". there improve way rather inelegant workaround? "unset plot" (that not exist).
thanks, luca
you can check i == 1 , utilize plot first plot , replot otherwise:
i = + 1 fstr = sprintf("a%d*x+b%d*sqrt(x-1)+c%d", monthn,monthn,monthn) if (i == 1) plot @fstr; else replot @fstr if (i < 6) reread; that works fine 4.4.4
macros plot iteration gnuplot
Comments
Post a Comment