我画了一个图,上面有一个向量的路径和这个向量在给定时间的位置。我在3D中使用quiver,但是当我试图在参数中使用scale
或{
ax = plt.axes(projection='3d')
ax.set_autoscalex_on(True)
ax.scatter3D(x, y, z, s=0.4 )
#x, y and z are arrays with coordinates of points
ax.quiver(0, 0, 0, x[10], y[10], z[10], color='red')
{}s'.format(step)
plt.show()
您希望使用
arrow_length_ratio
而不是scale
,因为您是用3d而不是2d打印的这是来自docs for 3d matplotlib objects。在
尝试类似于:
相关问题 更多 >
编程相关推荐