如何在gnuplot的二维热力图上标记一些点?

3

我正在使用简单的方案从我的数据中绘制2D热图,就像这样:

set pm3d map
set pm3d interpolation 5,5
splot "file"

现在我需要在这个数据上标记几个点,可能是用白色。我尝试过:
splot "file"; plot "points"

它无法正常工作,提示“无法在2D图中使用pm3d”。

1个回答

3
文件长什么样子?你可以执行以下操作:

splot 'file' with pm3d, 'points' with points linecolor rgb "white"

不过根据'points'的情况,您可能需要添加一个using规范:

splot 'file' with pm3d, 'points' using 1:2:(0.0) with points linecolor rgb "white"

非常感谢,这很有帮助! 我的文件看起来像这样: x y z 其中z是一种颜色,在我的情况下是磁场幅度。 - Alej

网页内容由stack overflow 提供, 点击上面的
可以查看英文原文,
原文链接