Title: Axes3D: factor out 3D coordinate guessing from format_coord() · Issue #4334 · matplotlib/matplotlib · GitHub
Open Graph Title: Axes3D: factor out 3D coordinate guessing from format_coord() · Issue #4334 · matplotlib/matplotlib
X Title: Axes3D: factor out 3D coordinate guessing from format_coord() · Issue #4334 · matplotlib/matplotlib
Description: To get the estimated (x,y,z) coordinate of a mouse event in a 3D figure we must parse these values from the string generated by Axes3D.format_coord. Wouldn't it be more useful to factor that out into a separate method (coord?) giving acc...
Open Graph Description: To get the estimated (x,y,z) coordinate of a mouse event in a 3D figure we must parse these values from the string generated by Axes3D.format_coord. Wouldn't it be more useful to factor that out in...
X Description: To get the estimated (x,y,z) coordinate of a mouse event in a 3D figure we must parse these values from the string generated by Axes3D.format_coord. Wouldn't it be more useful to factor that ou...
Opengraph URL: https://github.com/matplotlib/matplotlib/issues/4334
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Axes3D: factor out 3D coordinate guessing from format_coord()","articleBody":"To get the estimated (x,y,z) coordinate of a mouse event in a 3D figure we must parse these values from the string [generated](https://github.com/matplotlib/matplotlib/blob/e2315d221251e62130e3cd73c39fe90b5924600f/lib/mpl_toolkits/mplot3d/axes3d.py#L1087-1125) by `Axes3D.format_coord`. Wouldn't it be more useful to factor that out into a separate method (`coord`?) giving access to `x, y, z = proj3d.inv_transform(xd, yd, z, self.M)`? `format_coord` would then simply convert that to the formatted string.\n\nThe question of how to extract these coordinates has been asked a few times on SO:\n\nhttp://stackoverflow.com/questions/6748184/matplotlib-plot-surface-get-the-x-y-z-values-written-in-the-bottom-right-cor\nhttp://stackoverflow.com/questions/28954611/how-to-extract-3d-mouse-coordinate-on-mouse-click-in-matplotlib-in-python\n\nand aside from duplicating the code within `format_coord` the best we can do is parse the values out of the generated string.\n","author":{"url":"https://github.com/ndawe","@type":"Person","name":"ndawe"},"datePublished":"2015-04-14T02:58:51.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":4},"url":"https://github.com/4334/matplotlib/issues/4334"}
| 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:d8f22f72-e7b5-81dc-dd18-6ea282886612 |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | 8F32:17402E:CBE5A5:112D599:6A543634 |
| html-safe-nonce | c47da57b7bb1f737e6a9a65b1ec7cfee8ec1c4b1895cfadea2043a3daf895f7d |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiI4RjMyOjE3NDAyRTpDQkU1QTU6MTEyRDU5OTo2QTU0MzYzNCIsInZpc2l0b3JfaWQiOiI5NjI4Mzk4MzAyNjE0MTM0MjgiLCJyZWdpb25fZWRnZSI6ImlhZCIsInJlZ2lvbl9yZW5kZXIiOiJpYWQifQ== |
| visitor-hmac | cc0acad2ffb8aeee72d8bab7be166d5a7a2d21e0af5e4a43a475bf3c720b9477 |
| hovercard-subject-tag | issue:68246746 |
| 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/4334/issue_layout |
| twitter:image | https://opengraph.githubassets.com/03251a8e2e715c181d21edb2d2c6ec06e909e8ea5f698933dd559c1743fed930/matplotlib/matplotlib/issues/4334 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/03251a8e2e715c181d21edb2d2c6ec06e909e8ea5f698933dd559c1743fed930/matplotlib/matplotlib/issues/4334 |
| og:image:alt | To get the estimated (x,y,z) coordinate of a mouse event in a 3D figure we must parse these values from the string generated by Axes3D.format_coord. Wouldn't it be more useful to factor that out in... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | ndawe |
| 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