Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Arc and pathpatch_2d_to_3d plots full ellipse #19550

Copy link
Copy link
Closed
@alspitz

Description

@alspitz
Issue body actions

Bug report

Bug summary

I'm trying to draw an arc with an arrow in a 3D plot (to visualize an angle) and am having trouble using pathpatch_2d_to_3d. The full circle is displayed when a 3D figure is used.

I found https://discourse.matplotlib.org/t/matplotlib-users-arc-and-art3d-pathpatch-2d-to-3d/21104, which is the exact same issue.
What's the best way to achieve the desired outcome?

Code for reproduction

import matplotlib.pyplot as plt
from matplotlib.patches import Arc
import mpl_toolkits.mplot3d.art3d as art3d

fig = plt.figure()
ax = plt.axes(projection='3d')
a = Arc((0.5, 0.5), width=0.5, height=0.5, angle=0, theta1=0, theta2=90)
ax.add_patch(a)
art3d.pathpatch_2d_to_3d(a, z=0, zdir='z')
plt.show()

Actual outcome

Figure_1

Expected outcome

I expect the arc to be 90 degrees, not a full circle.

Matplotlib version
Matplotlib 3.3.4 w/ Python 3.9.1.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      Morty Proxy This is a proxified and sanitized view of the page, visit original site.