Plot degenerate ellipse using units other than km

Related: Psxy -SE option ellipse axis units

Hi all, I’m trying to plot a degenerate ellipse (circle) by specifying lon, lat, and diameter in degrees. I am able to plot a circle with diameter specified in km, but only because that’s the default. The GMT docs here say I can

…append desired unit to the dimension(s) [Default is k for km]…

but I’m unsure of how to accomplish this using PyGMT. MWE below.

import pygmt

fig = pygmt.Figure()
fig.coast(region='g', projection='E0/0/6i', shorelines=True, frame=True)
fig.plot(x=0, y=0, style='c0.1i', color='red')

# This works for 5000 km radius
fig.plot(data=[[0, 0, 10000]], style='E-', pen='2p,red')

# How to do this in units of degrees (target 100° diameter)?
fig.plot(data=[[0, 0, '100d']], style='E-', pen='2p,blue')

fig.show()

Hi Liam,

I took a quick look and also had difficulty accomplishing the task. Paul just implemented a new feature in GMT that should make this much easier with GMT 6.4 - https://github.com/GenericMappingTools/gmt/pull/6282

Here is an example using that feature to plot a 3 arc degree degenerate ellipse:

fig.plot(data=[[0, 0, 3]], style='E-d', pen='2p,red')

Thanks, Meghan! Looking forward to that enhancement.