Title: Feature Idea: Make subplots return an AxisList object instead of a numpy array · Issue #9434 · matplotlib/matplotlib · GitHub
Open Graph Title: Feature Idea: Make subplots return an AxisList object instead of a numpy array · Issue #9434 · matplotlib/matplotlib
X Title: Feature Idea: Make subplots return an AxisList object instead of a numpy array · Issue #9434 · matplotlib/matplotlib
Description: Hey, This is a short idea I had when creating complex graphs with multiple subplots. Sometimes you want to apply the same actions to multiple subplots and a way that feels very natural would be something like this: fig, axs = plt.subplot...
Open Graph Description: Hey, This is a short idea I had when creating complex graphs with multiple subplots. Sometimes you want to apply the same actions to multiple subplots and a way that feels very natural would be som...
X Description: Hey, This is a short idea I had when creating complex graphs with multiple subplots. Sometimes you want to apply the same actions to multiple subplots and a way that feels very natural would be som...
Opengraph URL: https://github.com/matplotlib/matplotlib/issues/9434
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Feature Idea: Make subplots return an AxisList object instead of a numpy array","articleBody":"Hey,\r\n\r\nThis is a short idea I had when creating complex graphs with multiple subplots.\r\nSometimes you want to apply the same actions to multiple subplots and a way that feels very natural would be something like this:\r\n\r\n````python\r\nfig, axs = plt.subplots(2, 2)\r\naxs[:, 0].set_ylabel('test')\r\n````\r\n\r\nThis does of course not work, but could be easily be achieved by returning a custom object that wraps a list of axes instances and overwrites the `__getitem__` method.\r\nOf course it would need to reimplement all axes methods, but it might be possible to do that by just forwarding all call in a modified `__getattribute__` or by automatically creating wrapped classmethods in a metaclass.\r\n\r\nWith such a custom object it might even be possible to support something like this:\r\n````python\r\naxs[:, 0].set_ylabel(['test1', 'test2'])\r\n````\r\n\r\nIf there is interest in such functionality, I would try to build a working prototype.\r\n\r\nOther than that, thanks to everybody for all the awesome work you put into matplotlib!\r\nRegards,\r\nArne\r\n","author":{"url":"https://github.com/AKuederle","@type":"Person","name":"AKuederle"},"datePublished":"2017-10-16T10:51:43.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":16},"url":"https://github.com/9434/matplotlib/issues/9434"}
| 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:1cb61594-59c0-230c-08f1-595d9902efcb |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | D446:23AA91:10F7D9B:16D0EEA:6A544DE6 |
| html-safe-nonce | d384b441048a4e7ee749f2131993bb2b72d316023c44b1a5c9f038b70350a9a1 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJENDQ2OjIzQUE5MToxMEY3RDlCOjE2RDBFRUE6NkE1NDRERTYiLCJ2aXNpdG9yX2lkIjoiMjkwMTA2MjE3NDcwMDIyODA3MCIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9 |
| visitor-hmac | c382bcbca1aaf1ad941a0c6b816741c2cbc8909f5fef525b3f901e1ea880d77c |
| hovercard-subject-tag | issue:265726917 |
| 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/9434/issue_layout |
| twitter:image | https://opengraph.githubassets.com/b6ab7e910d0a754b51215770b8f482fda0b072fa653e9cc51b953611ea123cf2/matplotlib/matplotlib/issues/9434 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/b6ab7e910d0a754b51215770b8f482fda0b072fa653e9cc51b953611ea123cf2/matplotlib/matplotlib/issues/9434 |
| og:image:alt | Hey, This is a short idea I had when creating complex graphs with multiple subplots. Sometimes you want to apply the same actions to multiple subplots and a way that feels very natural would be som... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | AKuederle |
| 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 | 07a982c1d40157c619b364352b704c3ce66bb332 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width