Linux 在 Gnuplot 中命名图例条目,同时从数据文件绘图
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/14741893/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me):
StackOverFlow
Naming the legend entry in Gnuplot, while plotting from a data file
提问by user1535776
I am plotting a data file with six columns in gnuplot. If the plot of column 2 against column 1 is x(t), I want that line in the legend something like x(t)
, NOT what I currently get for column two against column one, "trial.dat" u 1:2
.
我正在 gnuplot 中绘制一个包含六列的数据文件。如果第 2 列对第 1 列的绘图是 x(t),我希望图例中的那条线类似于x(t)
,而不是我目前从第二列对第一列得到的"trial.dat" u 1:2
。
How would I name the legend line, then?
那我该如何命名传奇线呢?
采纳答案by mgilson
You use the title
keyword in the plot line:
您title
在情节线中使用关键字:
plot 'trial.dat' u 1:2 title "x(t)"
You can also get rid of the legend entry all together by using notitle
.
您还可以使用notitle
.