Gnuplot 如何在标签2上显示值

Gnuplot 如何在标签2上显示值,gnuplot,Gnuplot,这是我的代码: set title "courbe" set xlabel "first" set ylabel "second" set y2label "third" plot "File.txt" using 1:2 with linespoints tit 'first', "File.txt" using 1:3 with linespoints tit 'second', "File.txt" using 1:4 with points tit 'third' 拜托,第三把斧头上

这是我的代码:

set title "courbe"
set xlabel "first" 
set ylabel "second"
set y2label "third"
plot "File.txt" using 1:2 with linespoints tit 'first', "File.txt" using 1:3 with linespoints tit 'second', "File.txt" using 1:4 with points tit 'third'
拜托,第三把斧头上没有数字,你有什么想法吗?


谢谢。

我怀疑这是您用于生成该绘图的实际脚本,因为第二个绘图命令的标题不匹配。除此之外,您实际上没有在y2轴上绘制任何东西。要在y2轴上放置某个对象,需要明确指定该对象(例如,
轴x1y2
)。比如:

set title "courbe"
set xlabel "first" 
set ylabel "second"
set y2label "third"
plot "File.txt" using 1:2 with linespoints title 'first',\
     "File.txt" using 1:3 with linespoints title 'second', \
     "File.txt" axes x1y2 using 1:4 with points title 'third'

应该这样做。

谢谢你的回答,我有一个错误:第1行的坏数据。你有什么想法吗?@user1735757——如果数据文件相当短,你可以将其与你正在处理的实际脚本一起发布,这样我们就可以玩了。如果没有看到数据文件和您正在使用的实际脚本,我只能猜测。