Title: Log-scale ignores Formatter · Issue #8517 · matplotlib/matplotlib · GitHub
Open Graph Title: Log-scale ignores Formatter · Issue #8517 · matplotlib/matplotlib
X Title: Log-scale ignores Formatter · Issue #8517 · matplotlib/matplotlib
Description: Bug report Bug summary Logarithmic scaling seems to break the label formatting. Code for reproduction import matplotlib.pyplot as plt from matplotlib import ticker import numpy as np p = np.linspace(1000, 500, 100) T = np.linspace(300, 2...
Open Graph Description: Bug report Bug summary Logarithmic scaling seems to break the label formatting. Code for reproduction import matplotlib.pyplot as plt from matplotlib import ticker import numpy as np p = np.linspac...
X Description: Bug report Bug summary Logarithmic scaling seems to break the label formatting. Code for reproduction import matplotlib.pyplot as plt from matplotlib import ticker import numpy as np p = np.linspac...
Opengraph URL: https://github.com/matplotlib/matplotlib/issues/8517
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Log-scale ignores Formatter","articleBody":"### Bug report\r\n\r\n**Bug summary**\r\nLogarithmic scaling seems to break the label formatting.\r\n\r\n**Code for reproduction**\r\n```python\r\nimport matplotlib.pyplot as plt\r\nfrom matplotlib import ticker\r\nimport numpy as np\r\n\r\n\r\np = np.linspace(1000, 500, 100)\r\nT = np.linspace(300, 200, p.size)\r\n\r\n\r\nfig, ax = plt.subplots()\r\nax.plot(T, p)\r\nax.set_yscale('log')\r\nax.yaxis.set_major_formatter(ticker.StrMethodFormatter('{x:.3f}'))\r\n\r\nplt.show()\r\n```\r\nThe issue is reproducible using different Formatters (e.g. FuncFormatter, ...).\r\n\r\n**Actual outcome**\r\n\r\n\r\n**Expected outcome**\r\nI would expect the axis to use the passed Formatter like the linear scaled axis does:\r\n\r\n\r\n\r\n**Matplotlib version**\r\n * Operating System: macOS Sierra (10.12.4) | Debian GNU/Linux 8.6\r\n * Matplotlib Version: 2.0.0 \r\n * Python Version: 3.6.1\r\n\r\nMatplotlib was installed from the conda-forge channel.\r\n\r\nThanks for your great work!\r\n\r\n/Lukas","author":{"url":"https://github.com/lkluft","@type":"Person","name":"lkluft"},"datePublished":"2017-04-20T08:41:38.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":3},"url":"https://github.com/8517/matplotlib/issues/8517"}
| 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:25a225ce-c3e4-c69b-f618-c322db754ef6 |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | DECA:2E411E:12CF321:1946D45:6A5342BE |
| html-safe-nonce | b4716b3279cf410f994dec60b8d34c1ed45fd1ba00b2bc597f86fb3416424464 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJERUNBOjJFNDExRToxMkNGMzIxOjE5NDZENDU6NkE1MzQyQkUiLCJ2aXNpdG9yX2lkIjoiNDUzNzM1NDE5ODA0MDM5NjQ3OSIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9 |
| visitor-hmac | a94b789de6beb8dceb7dc42b24116d3ae306cb86c4a76188686ce96c90cdd765 |
| hovercard-subject-tag | issue:222991296 |
| 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/8517/issue_layout |
| twitter:image | https://opengraph.githubassets.com/e712bb2a5d19fbe3831a42cf167f125cea195c0094f6b81dba6436e4f009c0a4/matplotlib/matplotlib/issues/8517 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/e712bb2a5d19fbe3831a42cf167f125cea195c0094f6b81dba6436e4f009c0a4/matplotlib/matplotlib/issues/8517 |
| og:image:alt | Bug report Bug summary Logarithmic scaling seems to break the label formatting. Code for reproduction import matplotlib.pyplot as plt from matplotlib import ticker import numpy as np p = np.linspac... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | lkluft |
| 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