|
From: pemilti <mic...@lt...> - 2008-09-03 14:01:23
|
Thomas Sefzick wrote: > >> OK, but how I can read the files with consecutive numbering, >> example: file1.dat, file2.dat,... >> and write the output to out1.gif, out2.gif,..? >> I've got a file whose name is used to generate other filenames >> with consecutive numbering. >> >> I want to do this like this schema: >> counter = counter + 1; >> set output 'out_'counter'.gif' >> plot 'NetzAus_'.counter'.dat' using 1:2 with lines axes x1y1 title "Strom >> [A]" >> if (counter<= counterMax) reread > > you need a start script and another script for the loop: > > start.plt: > > set grid > set title 'Data Netz Aus' > set xlabel 'Zeit [s]' > set terminal gif tiny size 1024,768 > set y2label > set y2tics > counter = 0 > counterMax = 100 > load 'loop.plt' > > loop.plt: > > counter = counter + 1; > set output 'out_'.counter.'.gif' > plot 'NetzAus_'.counter.'.dat' using 1:2 with lines axes x1y1 title "Strom > [A]" > if (counter<= counterMax) reread > > and then you start the whole thing at the gnuplot > command prompt: > > load 'start.plt' > > @ Thomas Sefzick Thanks for your great and fast help. It works very nice. :jumping: @All Please note: If you want to start with 0 you have to set counter to -1. -- View this message in context: http://www.nabble.com/read-and-plot-a-lot-of-files-with-consecutive-numbering-tp19272692p19289877.html Sent from the Gnuplot - User mailing list archive at Nabble.com. |