我如何告诉 gnuplot 为 ytics 显示更多数字?

How can I tell gnuplot to show more digits for ytics?

我有一组八位数不同的数据。我的数据如下所示:

------------------------------------------------------------
 Electrostatic Potential
------------------------------------------------------------
Position (um), Potential (V)
                   0,     -0.0397018620551
    0.00713979294463,     -0.0397018617044
     0.0142081879598,     -0.0397018613574
     0.0212058990249,      -0.039701861014
     0.0281336329792,     -0.0397018606745
     0.0349920895941,     -0.0397018603389
     0.0417819616428,     -0.0397018600072
      0.048503934971,     -0.0397018596795
     0.0551586885659,     -0.0397018593558
     0.0617468946249,     -0.0397018590363
     0.0682692186233,     -0.0397018587208
     0.0747263193817,     -0.0397018584096
     0.0811188491325,     -0.0397018581026
     0.0874474535858,     -0.0397018577998

而且,如前所述,它在八位数中变化非常缓慢。当我绘制它时,我得到以下图片:

如您所见,ytics 并未显示所有数字,并且相同的值重复了几次。这使得正确阅读它有点困难。

我有办法在垂直轴上放置更多数字吗? 或者,如果您有任何关于如何以一种好看的方式显示数据的建议,我将不胜感激。

到目前为止,这是我的 gnuplot 代码:

set title font ",14"

set xlabel font ",14"
set xtics font ",14"
set ylabel font ",14"
set ytics font ",12"
set key font ",14"

#set key at 0.65, -3.5
set lmargin 17
set bmargin 5
set ylabel offset -3.5,0,0
set ylabel "Tensión (mV) "
set xlabel 'Longitud ({/Symbol m}m)'

plot 'G=1e20.txt' u 1:(*100000) title 'G = 1e20 cm^{-3}', \
'G=2e20.txt' u 1:(*100000) title 'G = 2e20 cm^{-3}', \
'G=5e20.txt' u 1:(*100000) title 'G = 5e20 cm^{-3}', \
'G=10e20.txt' u 1:(*100000) title 'G = 10e20 cm^{-3}',

提前致谢!

您可以使用 set ytics 指定格式,例如:

set ytics font ",12"    format "%.5f"

要求 5 位浮点数精度。