Title: GeoAxes features request · Issue #397 · proplot-dev/proplot · GitHub
Open Graph Title: GeoAxes features request · Issue #397 · proplot-dev/proplot
X Title: GeoAxes features request · Issue #397 · proplot-dev/proplot
Description: Description Hello, I am a regular user of proplot with which I can draw beautiful geoscience plots. CartesianAxes provides powerful contol on axes major and minor ticks. But for GeoAxes, it seems that proplot only provides control of lat...
Open Graph Description: Description Hello, I am a regular user of proplot with which I can draw beautiful geoscience plots. CartesianAxes provides powerful contol on axes major and minor ticks. But for GeoAxes, it seems t...
X Description: Description Hello, I am a regular user of proplot with which I can draw beautiful geoscience plots. CartesianAxes provides powerful contol on axes major and minor ticks. But for GeoAxes, it seems t...
Opengraph URL: https://github.com/proplot-dev/proplot/issues/397
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"GeoAxes features request","articleBody":"\u003c!-- Thanks for helping us make proplot a better package! If this is a bug report, please use the template provided below. If this is a feature request, you can delete the template text (just try to be descriptive with your request). --\u003e\r\n\r\n### Description\r\n\r\nHello, I am a regular user of proplot with which I can draw beautiful geoscience plots. CartesianAxes provides powerful contol on axes major and minor ticks. But for GeoAxes, it seems that proplot only provides control of lat and lon grid lines. If I want to show lat and lon ticks for NCL style geographic plots, I can only call the matplotlib method ax.tick_params(). As shown below, the code will become redundant and inconsistent with the proplot style. If the GeoAxes.format can control the lat and lon ticks, I think it will be a nice feature.\r\n\r\n### Steps to reproduce\r\n\r\n```python\r\n# your code here\r\n# we should be able to copy-paste this into python and exactly reproduce your bug\r\nimport proplot as pplt\r\nimport cartopy.crs as ccrs\r\nimport matplotlib.ticker as ticker\r\nfrom cartopy.mpl.ticker import LongitudeFormatter, LatitudeFormatter\r\n\r\nfig = pplt.figure(refwidth=5)\r\n\r\naxs = fig.subplots(nrows=1, ncols=1, proj=\"cyl\", proj_kw={\"lon_0\": 200}, right=\"3em\")\r\n\r\naxs.format(\r\n suptitle=\"Figure with NCL sytle by matplotlib\",\r\n suptitlesize=12,\r\n suptitlepad=10,\r\n land=True,\r\n landcolor=\"k\",\r\n coast=True,\r\n coastlinewidth=1,\r\n reso=\"lo\",\r\n latlim=(-90, 90),\r\n lonlim=(0, 360),\r\n grid=False,\r\n)\r\n\r\n\r\naxs.set_xticks(np.arange(0, 381, 60), crs=ccrs.PlateCarree())\r\naxs.set_yticks(np.arange(-90, 91, 30), crs=ccrs.PlateCarree())\r\n\r\n\r\nlon_formatter = LongitudeFormatter(zero_direction_label=False)\r\nlat_formatter = LatitudeFormatter()\r\naxs.xaxis.set_major_formatter(lon_formatter)\r\naxs.yaxis.set_major_formatter(lat_formatter)\r\n\r\naxs.xaxis.set_tick_params(labelsize=10, pad=5)\r\naxs.yaxis.set_tick_params(labelsize=10, pad=5)\r\n\r\naxs.xaxis.set_minor_locator(ticker.IndexLocator(base=30, offset=10))\r\naxs.yaxis.set_minor_locator(ticker.MultipleLocator(15))\r\n\r\naxs.tick_params(\r\n which=\"major\",\r\n direction=\"out\",\r\n length=10,\r\n width=1.5,\r\n colors=\"k\",\r\n top=\"on\",\r\n bottom=\"on\",\r\n left=\"on\",\r\n right=\"on\",\r\n)\r\n\r\naxs.tick_params(\r\n which=\"minor\",\r\n direction=\"out\",\r\n length=5,\r\n width=0.8,\r\n top=\"on\",\r\n bottom=\"on\",\r\n left=\"on\",\r\n right=\"on\",\r\n)\r\n\r\naxs.grid(False)\r\n```\r\n\r\n**Expected behavior**: \r\n\r\n\r\n\r\n### Proplot version\r\n\r\n\r\nmatplotlib.__version__ = 3.2.2\r\nproplot.version = 0.9.5","author":{"url":"https://github.com/Dearsomeone","@type":"Person","name":"Dearsomeone"},"datePublished":"2022-11-11T04:11:17.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":1},"url":"https://github.com/397/proplot/issues/397"}
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:80eaf94f-91ca-63f0-e362-d4600fc2c659 |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | A834:1E4FEF:3295C88:41FF9FA:696B8BB9 |
| html-safe-nonce | 1f894263bd2f7280728bcd2c5a155578ed59cb9bf8d52cc0c33b6b4a9539f37b |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJBODM0OjFFNEZFRjozMjk1Qzg4OjQxRkY5RkE6Njk2QjhCQjkiLCJ2aXNpdG9yX2lkIjoiMTgyMjIwMzYzMTU5MTE5NzYyNSIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9 |
| visitor-hmac | b27bd530f5909d55b9c7c77ea4ae1524a456d58deec0b4078f7f4d7cb6eeacf6 |
| hovercard-subject-tag | issue:1444899636 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/proplot-dev/proplot/397/issue_layout |
| twitter:image | https://opengraph.githubassets.com/74f37eddf95cad5ebf913990db378565578afc9cb712c65f6aca47838ab3a15d/proplot-dev/proplot/issues/397 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/74f37eddf95cad5ebf913990db378565578afc9cb712c65f6aca47838ab3a15d/proplot-dev/proplot/issues/397 |
| og:image:alt | Description Hello, I am a regular user of proplot with which I can draw beautiful geoscience plots. CartesianAxes provides powerful contol on axes major and minor ticks. But for GeoAxes, it seems t... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | Dearsomeone |
| hostname | github.com |
| expected-hostname | github.com |
| None | 5f99f7c1d70f01da5b93e5ca90303359738944d8ab470e396496262c66e60b8d |
| turbo-cache-control | no-preview |
| go-import | github.com/proplot-dev/proplot git https://github.com/proplot-dev/proplot.git |
| octolytics-dimension-user_id | 108025793 |
| octolytics-dimension-user_login | proplot-dev |
| octolytics-dimension-repository_id | 113293661 |
| octolytics-dimension-repository_nwo | proplot-dev/proplot |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 113293661 |
| octolytics-dimension-repository_network_root_nwo | proplot-dev/proplot |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 82560a55c6b2054555076f46e683151ee28a19bc |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width