通常在交互使用gnuplot时,我会:gnuplot> plot "state_log_6548032.data" using 4 with lines lt -1 lw 0.5 title "X axis" ,\
>"state_log_6548032.data" using 5 with lines lt 1 lw 0.5 title "Y axis" ,\
>"state_log_6548032.data" using 6 with lines lt 2 lw 0.5 title "Z axis"
但是,当我尝试使用子流程从python执行相同操作时:gnuplot.write( "plot \"%s\" using 1 with lines lt -1 lw 0.5 title 'X axis' ,\ \n" %filename )
gnuplot.write( "plot \"%s\" using 2 with lines lt 1 lw 0.5 title 'Y axis' ,\ \n" %filename )
gnuplot.write( "plot \"%s\" using 3 with lines lt 2 lw 0.5 title 'Z axis' \n" %filename )
我得到以下错误:gnuplot> plot "state_log_6548032.data" using 1 with lines lt -1 lw 0.5 title 'X axis' ,\
^
line 0: invalid character \
gnuplot> plo