|
From: Jon <dev...@gm...> - 2018-11-04 21:22:47
|
Dear All, I would like to define a variable and then use it in the linux command within a gnuplot script, how to successfully do that? An example is provided below ========================== set macro pos=2 tgt="`ls ../../.. | head -n pos | tail -n 1`" set term pngcairo transparent color solid set out @tgt.'_file.png' p sin(x) set out ========================== note pos is the variable I would like to define in the script to be used in the linux command ls ../../.. | head -n pos | tail -n 1 but it cannot be sent over. Is there way to realize the like functionality within gnuplot? Thanks, Sincerely, Jon |