Skip to content

Should LongitudeFormatter and LatitudeFormatter convert projected coordinates to dms by default? #292

Open
@gepcel

Description

@gepcel

Two examples first:

Example 1: notice the longitude labels of 2nd axis:

fig, axs = pplt.subplots(ncols=2,proj=['cyl', 'merc'],share=False)
axs.format(labels='all')
axs[0].format(lonlocator=(0.6, 113.25))
axs[1].format(lonlocator=(0.6, 113.25))

Image

Example 2:

fig=plt.figure(figsize=(8,3))
ax0 = fig.add_subplot(1,2,1,projection=ccrs.PlateCarree())
ax0.gridlines(draw_labels=True,xlocs=(0.6, 113.25))
extent = ax0.get_extent(crs=ccrs.PlateCarree())
ax1 = fig.add_subplot(1,2,2, projection=ccrs.Mercator())
ax1.gridlines(draw_labels=True,xlocs=(0.6, 113.25))

Image

Seems that cartopy converts coordinates of mercator to platecarree by default (like 66791.6944759644 to 0.6°E), but ultraplot does not.
And also, the ax.set_xitcks() method of cartopy also has a crs parameter (doc).
But lonlocator_kw of ultraplot doesn't seem to accept crs, am I missing something?

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingquestionFurther information is requested

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions