Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.graphics.apps.gnuplot > #4497
| X-Received | by 2002:ac8:4d03:0:b0:3a5:1b18:7747 with SMTP id w3-20020ac84d03000000b003a51b187747mr35994112qtv.538.1667814792334; Mon, 07 Nov 2022 01:53:12 -0800 (PST) |
|---|---|
| X-Received | by 2002:a25:4fc1:0:b0:6bc:c570:f99e with SMTP id d184-20020a254fc1000000b006bcc570f99emr47168228ybb.58.1667814792039; Mon, 07 Nov 2022 01:53:12 -0800 (PST) |
| Path | csiph.com!weretis.net!feeder6.news.weretis.net!usenet.blueworldhosting.com!feed1.usenet.blueworldhosting.com!peer02.iad!feed-me.highwinds-media.com!news.highwinds-media.com!news-out.google.com!nntp.google.com!postnews.google.com!google-groups.googlegroups.com!not-for-mail |
| Newsgroups | comp.graphics.apps.gnuplot |
| Date | Mon, 7 Nov 2022 01:53:11 -0800 (PST) |
| In-Reply-To | <tk6cdf$er8v$1@solani.org> |
| Injection-Info | google-groups.googlegroups.com; posting-host=148.81.46.176; posting-account=zy6fMAoAAACeC4ovRlW3V5OdiBlIWiQw |
| NNTP-Posting-Host | 148.81.46.176 |
| References | <db4a49ca-2e44-4f78-8619-3d165b29404fn@googlegroups.com> <tk6cdf$er8v$1@solani.org> |
| User-Agent | G2/1.0 |
| MIME-Version | 1.0 |
| Message-ID | <f84cec9e-e72a-4a64-aabe-9c789b33cea3n@googlegroups.com> (permalink) |
| Subject | Re: animation from data files |
| From | Russell Kajouri <rasoulkajouri@gmail.com> |
| Injection-Date | Mon, 07 Nov 2022 09:53:12 +0000 |
| Content-Type | text/plain; charset="UTF-8" |
| X-Received-Bytes | 2664 |
| Xref | csiph.com comp.graphics.apps.gnuplot:4497 |
Show key headers only | View raw
Hi
I think that there is no need to use %f, and you can put the name of the file and its definition into the loop, and then it works better!
n=100
while (n<=10000) {
fname = sprintf('data_%d.dat',n)
plot fname
n=n+100
}
On Saturday, November 5, 2022 at 8:09:37 PM UTC+1, Karl Ratzsch wrote:
> Something like this?
>
> fname(n) = sprintf('data_%.f.dat',n)
>
> n=100
> while (n<=10000) {
> plot fname(n)
> n=n+100
> }
>
>
>
>
> Am 02.11.2022 um 06:45 schrieb Shahid Maqbool:
> > Dear all,
> >
> > I have data files in the order like:
> >
> > data_100.dat
> > data_200.dat
> > data_300.dat
> > ...
> > data_10000.dat
> >
> > here 100, 200, 300, ..., 10000 are the time steps.
> >
> > I can successfully plot surface plot for data file e.g., 'data_10.dat' with the command i.e.,
> >
> > splot 'data_100.dat' matrix with pm3d notitle
> >
> > Now, i want to make animation for my data files to see the
> > continuous evolution of the system.
> >
> > I have gone throught the book 'Gnuplot in Action' and section 11.5 shows some animations, but it is not telling about loading different files. Also the online demos like
> >
> > https://gnuplot.sourceforge.net/demo/animate2.html
> >
> > are not very helpful in this case.
> >
> > So my question is, which commands or keywords should i use to load the continuous files and display the animation on the console?
> >
> > Thanks a lot.
> >
> > Best regards,
> > Shahid
Back to comp.graphics.apps.gnuplot | Previous | Next — Previous in thread | Next in thread | Find similar
animation from data files Shahid Maqbool <shahid718@gmail.com> - 2022-11-01 22:45 -0700
Re: animation from data files Olaf Schultz <o.schultz@enhydralutris.de> - 2022-11-02 16:29 +0100
Re: animation from data files Karl Ratzsch <mail.kfr@gmx.net> - 2022-11-05 20:09 +0100
Re: animation from data files Russell Kajouri <rasoulkajouri@gmail.com> - 2022-11-07 01:53 -0800
Re: animation from data files Shahid Maqbool <shahid718@gmail.com> - 2022-11-07 18:58 -0800
Re: animation from data files Jörg Buchholz <bookwood4new@freenet.de> - 2022-11-08 07:01 +0100
csiph-web