Title: set_rgrids() in a polar plot cannot set ticklabel size · Issue #17463 · matplotlib/matplotlib · GitHub
Open Graph Title: set_rgrids() in a polar plot cannot set ticklabel size · Issue #17463 · matplotlib/matplotlib
X Title: set_rgrids() in a polar plot cannot set ticklabel size · Issue #17463 · matplotlib/matplotlib
Description: Bug report In a polar plot, I want to set the sizes of the r and theta ticklabels. While setting the theta ticklabel size works with the method set_thetagrids, setting the r ticklabel size with set_rgrids does not work. As an aside, I fi...
Open Graph Description: Bug report In a polar plot, I want to set the sizes of the r and theta ticklabels. While setting the theta ticklabel size works with the method set_thetagrids, setting the r ticklabel size with set...
X Description: Bug report In a polar plot, I want to set the sizes of the r and theta ticklabels. While setting the theta ticklabel size works with the method set_thetagrids, setting the r ticklabel size with set...
Opengraph URL: https://github.com/matplotlib/matplotlib/issues/17463
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"set_rgrids() in a polar plot cannot set ticklabel size","articleBody":"### Bug report\r\n\r\nIn a polar plot, I want to set the sizes of the r and theta ticklabels. While setting the theta ticklabel size works with the method `set_thetagrids`, setting the r ticklabel size with `set_rgrids` does not work.\r\n\r\nAs an aside, I find it confusing that some functions for setting theta parameters require arguments in radians (e.g., `set_thetalim`), while others require arguments in degrees (e.g., `set_thetagrids`).\r\n\r\n**Code snippet**\r\n```python\r\nfrom matplotlib import pyplot as plt\r\nimport numpy as np\r\n\r\nfig = plt.figure()\r\nax = plt.axes(polar=True)\r\nax.set_thetalim(0., np.pi/4.)\r\nax.set_rlim(0., 2.)\r\n\r\n# set the size of theta ticklabels (works)\r\nthetatick_locs = np.linspace(0.,45.,4)\r\nthetatick_labels = [u'%i\\u00b0'%np.round(x) for x in thetatick_locs]\r\nax.set_thetagrids(thetatick_locs, thetatick_labels, fontsize=16)\r\n\r\n# set the size of r ticklabels (does not work)\r\nrtick_locs = np.arange(0.5,2.0,0.7)\r\nrtick_labels = ['%.1f'%r for r in rtick_locs]\r\nax.set_rgrids(rtick_locs, rtick_labels, fontsize=16)\r\n\r\nplt.show()\r\n```\r\n\r\n**Actual outcome**\r\nSee [figure](https://gmao.gsfc.nasa.gov/gmaoftp/sourish/bug_report_graphics/polar_plot_bug.png)\r\n\r\n**Expected outcome**\r\nI expect to be able to set the font properties of r ticklabels. Other settings, such as trying to set the font weight, does not work either.\r\n\r\n**Matplotlib version**\r\n * Operating system: Macos 10.15.4 (Catalina)\r\n * Matplotlib version: 3.2.1 (installed via macports)\r\n * Matplotlib backend: Qt5Agg\r\n * Python version: 3.8.2 (installed via macports)\r\n","author":{"url":"https://github.com/AgilentGCMS","@type":"Person","name":"AgilentGCMS"},"datePublished":"2020-05-20T14:19:04.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":6},"url":"https://github.com/17463/matplotlib/issues/17463"}
| 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:850af808-8748-8d87-646d-bfba22005f15 |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | B554:22243D:421662:5F3FAB:6A549BC3 |
| html-safe-nonce | c18180845e73903444490d03108b902e2a67345a5564c86b4bb1d2e53266dc4a |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJCNTU0OjIyMjQzRDo0MjE2NjI6NUYzRkFCOjZBNTQ5QkMzIiwidmlzaXRvcl9pZCI6IjY4MzUyMTQzNDA1MTk2NjQ1NzkiLCJyZWdpb25fZWRnZSI6ImlhZCIsInJlZ2lvbl9yZW5kZXIiOiJpYWQifQ== |
| visitor-hmac | 2d71041e3a64c693e58803f6eb672fda3d6ee2d6be48716e5f2101ff78ba0e71 |
| hovercard-subject-tag | issue:621801128 |
| 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/matplotlib/matplotlib/17463/issue_layout |
| twitter:image | https://opengraph.githubassets.com/c9fe521222727295a4e044a534a12aa25ef7c90a3cd8179c46902a3ec2db3122/matplotlib/matplotlib/issues/17463 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/c9fe521222727295a4e044a534a12aa25ef7c90a3cd8179c46902a3ec2db3122/matplotlib/matplotlib/issues/17463 |
| og:image:alt | Bug report In a polar plot, I want to set the sizes of the r and theta ticklabels. While setting the theta ticklabel size works with the method set_thetagrids, setting the r ticklabel size with set... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | AgilentGCMS |
| hostname | github.com |
| expected-hostname | github.com |
| None | b9a586c06a05a7a86fc7e3f4dbd03e42f6869085879aa184aa6369456dbd50fb |
| turbo-cache-control | no-preview |
| go-import | github.com/matplotlib/matplotlib git https://github.com/matplotlib/matplotlib.git |
| octolytics-dimension-user_id | 215947 |
| octolytics-dimension-user_login | matplotlib |
| octolytics-dimension-repository_id | 1385122 |
| octolytics-dimension-repository_nwo | matplotlib/matplotlib |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 1385122 |
| octolytics-dimension-repository_network_root_nwo | matplotlib/matplotlib |
| 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 | f8cfff6384f62259baea531c7f58bc7040f8dd92 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width