【发布时间】:2019-03-12 16:13:31
【问题描述】:
我想使用 Gnuplot 脚本绘制多个文件。
但是,我在使其完美时遇到了一些麻烦。
但是,线点图同时触及 x 轴和 y 轴。
因此,我想在xrange 和yrange 上添加额外的空间并得到
它不会触及我的轴。
我可以手动使用 set xrange 和 set yrange。
但是,我需要绘制 100 多个不同的文件,这样做会非常耗时。
有什么方法可以自动将xrange 和yrange 的大小增加一些单位?
我的 Gnuplot 代码如下。
#!/usr/bin/env gnuplot
set terminal epslatex size 7.5,3 standalone
set output 'pareto.tex'
set style fill solid 0.8
set ytics nomirror
set xtics nomirror
set grid lc rgb "#F2F2F2"
set xlabel 'Z_1'
set ylabel 'Z_2'
set xrange [170:215]
set yrange [7:40]
set style line 1 lt rgb "#000000" lw 12 pt 7 pointsize 3
plot "../exact.dat" using 1:2 title '$aug\,\epsilon$-CM' with linespoints ls 1
unset output
set output # finish the current output file
system('pdflatex --interaction=batchmode pareto.tex')
unset terminal
system
【问题讨论】: