# plt.plot connects datapoints with lines:
x = [0,1,2]
y = [1,4,3]
plt.plot(x,y)
![enter image description here](https://i.stack.imgur.com/dXQeo.png)
#note that lines are drawn between adjacent elements in the list,
#so a line from (0,1) to (1,4) and then to (2,3)
# if the order of the datapoints is changed, the position of the datapoints
# remains unchanged, but now lines are drawn between different points
x = [2,0,1]
y = [3,1,4]
plt.plot(x,y)
![enter image description here](https://i.stack.imgur.com/IBHAl.png)
Таким образом, причина, по которой вы видите все перекрещивание на вашем участке является то, что вы строите несортированные данные.
Если вы просто хотите скопировать сюжет из Excel, используйте plt.scatter
. Этот график только точки данных и не рисует связи между ними.
x = [2,0,1]
y = [3,1,4]
plt.scatter(x,y)
![enter image description here](https://i.stack.imgur.com/bNWEH.png)