gpt4 book ai didi

linux - Gnuplot 垂直虚线

转载 作者:行者123 更新时间:2023-12-03 09:51:36 27 4
gpt4 key购买 nike

我想用 GNUPLOT 在我的图表上添加一条灰色虚线垂直线。

我的终端是;

set terminal postscript portrait enhanced color dashed lw 1 "DejaVuSans" 12 size 6,6
set output "pic.ps"
set xrange [30:110]
plot 'smth.txt' w lines ls 7 t ""

我已经研究了几个想法,但似乎没有关于如何在假设 x = 40(该线将与 y 轴平行)垂直获得灰色虚线的解释

The image I have is like this;

最佳答案

关键是使用set arrow命令并移除头部以使其成为一行:

set arrow from 40,0 to 40,100 nohead lc rgb 'red' dt 2

您的图表未指定任何 y 值,因此将其调整为“大于所需”的值。

对于破折号类型 ( dt ), checkout p.42 of manual .它依赖于终端(我没有尝试使用 postscript),但您可以根据需要进行调整。

关于linux - Gnuplot 垂直虚线,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/59224389/

27 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com