首页 > 解决方案 > 带有 epslatex 的 Gnuplot:如何在生成输出时处理错误

问题描述

我有以下脚本,它生成一个 .eps 文件作为最终输出

set terminal epslatex color size 4.5in,4.5in standalone
set output 'profile.tex'
set xlabel "Time"
set ylabel "$d_g$"
set xrange [:500000]
set yrange [:40]
set size ratio 1.05
set key right bottom
pl 'file.txt' u 2:(17.75-$4) w l
unset out
set out
system('latex profile.tex && dvips profile.dvi && ps2pdf profile.ps')
system('mv profile.ps CON_GBD.eps')
unset terminal
set out

使用上述脚本时,出现以下错误

! Missing $ inserted.
<inserted text> 
                $
l.175     \gplfronttext

? 

谁能指出为什么会出现这个错误?

标签: plotgnuplot

解决方案


推荐阅读