sunpy.visualization.wcsaxes_compat.gca_wcs(wcs, fig=None, slices=None)[source] [edit on github]

Get the current axes, and return a WCSAxes if possible.

  • wcs (astropy.wcs.WCS) – A WCS object used to create a new axes.

  • fig (matplotlib.figure.Figure) – The figure in which to check for the axes.

  • slices (tuple) – slices is passed to WCSAxes to describe which two dimensions of the WCS object are being plotted. This slices the multidimensional wcs object in the way it needs to be sliced.


matplotlib.axes.Axes or WCSAxes – The current axes, or a new one if created.