在Gnuplot中绘制有序对的对


6

如果我有一个包含4列的数据文件:

x1, y1, x2, y2,

如何可以绘制连接线(x1, y1)(x2, y2)为每个元素(行)?

我认为这很容易,但是我一直玩了一个小时都没有成功。

Answers:


2
plot "DATA" using 1:2:($3-$1):($4-$2) with vectors nohead

向量样式读取四列(xydxdy)并绘制一个从(xy)到(x + dxy + dy)的向量。

nohead 防止gnuplot绘制箭头。

By using our site, you acknowledge that you have read and understand our Cookie Policy and Privacy Policy.
Licensed under cc by-sa 3.0 with attribution required.