【问题标题】:How to zoom_in 3D plot in matplotlib如何在 matplotlib 中放大 3D 绘图
【发布时间】:2021-03-08 23:29:16
【问题描述】:

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

我想从上面的图片中提取这个

【问题讨论】:

    标签: python python-3.x matplotlib 3d


    【解决方案1】:

    对于 3D 观看距离/角度,您需要适当指定 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)
    

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 2021-11-06
      • 2013-07-19
      • 2013-08-06
      • 2020-12-02
      • 2021-03-06
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多