In article < XXXX@XXXXX.COM >,
The traditional way is to run gnuplot via piped commands from a
script, and have the script substitute in the appropriate file name
when it stuffs the plot command in the end of the pipe.
Here's another way, introduced in version 4.1
 setenv FILE "myfilename.dat"
 gnuplot myscript.plt
where myscript.plt contains:
filename = system("getenv FILE")
plot filename using 1:2 with points title filename
That's a csh/tcsh version, but it's easily adapted to a shell
of your choice.
Ethan A Merritt