如何在 matplotlib 中 zoom_in 3D 绘图

How to zoom_in 3D plot in matplotlib

我有一个数据集,我用 3D 显示它。现在我必须深入研究那个 3D 情节。因为上面有一个洞,我必须找到它。现在我不知道该怎么做。我显示的 3D。

我想从上图中提取这个

对于 3D 观看 distance/angles,您需要适当指定 3 个参数:

ax3d.azim = 150   # z rotation (default=270)
ax3d.elev = 42    # x rotation (default=0)
ax3d.dist = 10    # define perspective (default=10)

如果要放大,ax3d.dist应设置为小于默认值。

然而,情节限制在这种情况下也很重要。还需要这些代码行:

ax3d.set_xlim3d(low_x, high_x)
ax3d.set_ylim3d(low_y, high_y)
ax3d.set_zlim3d(low_z, high_z)