简体   繁体   English

使用八度音阶图,如何用连接线绘制点?

[英]With octave plot, how to plot points with connection line?

I have data like this: 我有这样的数据:

x = [23, 25, 28, 29, ...]
y = [25, 38, 38, 28, ...]

Now, I can plot the points with plot(x, y, '.r'); 现在,我可以用积分绘制点plot(x, y, '.r');

I collect above points data by a time sequence, now, I want to connect the points with a line, so that I can see which is the next point of one specific point. 我按时间顺序收集上面的点数据,现在,我想用一条线连接点,这样我就可以看到哪一个是特定点的下一个点。

plot() can be used to draw points-and-lines like this: plot()可用于绘制点和线,如下所示:

plot(x, y, 'o-r');

This draws the points as circles, and connects them with lines, all in red. 这将点绘制为圆圈,并将它们与线条连接,全部为红色。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM