Inset_axes in polar coordinates

Deadly 提交于 2021-01-29 10:22:26

问题


I am using matplotlib.axes.Axes.inset_axes (https://matplotlib.org/3.1.1/api/_as_gen/matplotlib.axes.Axes.inset_axes.html) to create an child axe of a an existing parent axe.

How do I set it to polar coordinates ? I can not use this: Matplotlib inset polar plot as 'Axes' object has no property 'polar'.

But inset_axes only returns Axes objects and not projections.polar.PolarAxes ..


回答1:


From the comment of ImportanceOfBeingErnest:

just use mpl_toolkits.axes_grid1.inset_locator.inset_axes() instead, with the parameter axes_class = matplotlib.projections.get_projection_class('polar').



来源:https://stackoverflow.com/questions/58595212/inset-axes-in-polar-coordinates

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!