Title: Hatches filling an empty color contour not saved in pdf · Issue #8431 · matplotlib/matplotlib · GitHub
Open Graph Title: Hatches filling an empty color contour not saved in pdf · Issue #8431 · matplotlib/matplotlib
X Title: Hatches filling an empty color contour not saved in pdf · Issue #8431 · matplotlib/matplotlib
Description: I am trying to create a contour plot with the contours filled with hatches and no color. The following example works if I save it to .png but when I save it to .pdf the output is just the axis. import numpy as np import matplotlib.pyplot...
Open Graph Description: I am trying to create a contour plot with the contours filled with hatches and no color. The following example works if I save it to .png but when I save it to .pdf the output is just the axis. imp...
X Description: I am trying to create a contour plot with the contours filled with hatches and no color. The following example works if I save it to .png but when I save it to .pdf the output is just the axis. imp...
Opengraph URL: https://github.com/matplotlib/matplotlib/issues/8431
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Hatches filling an empty color contour not saved in pdf ","articleBody":"\r\n\r\nI am trying to create a contour plot with the contours filled with hatches and no color. The following example works if I save it to .png but when I save it to .pdf the output is just the axis.\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n```python\r\nimport numpy as np\r\nimport matplotlib.pyplot as plt\r\n\r\n\r\n\r\ndelta = 0.025\r\n\r\nx = y = np.arange(-3.0, 3.01, delta)\r\n\r\n\r\nX, Y = np.meshgrid(x, y)\r\nZ1 = plt.mlab.bivariate_normal(X, Y, 1.0, 1.0, 0.0, 0.0)\r\nZ2 = plt.mlab.bivariate_normal(X, Y, 1.5, 0.5, 1, 1)\r\nZ = 10 * (Z1 - Z2)\r\n\r\n\r\nlevels=[0,1]\r\nplt.contourf(X, Y, Z/X, \r\n levels,\r\n #alpha=0.5,\r\n colors='none', label='AGH',\r\n hatches=['\\\\'])\r\n\r\nplt.tight_layout() \r\n\r\nplt.savefig('GitHub.pdf')\r\nplt.show()\r\n```\r\n\r\n\r\n\r\n\r\n\r\nI am using Matplotlib2.00 in Linux, installed from source.\r\n\r\n","author":{"url":"https://github.com/andres0l1","@type":"Person","name":"andres0l1"},"datePublished":"2017-04-05T11:41:41.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":13},"url":"https://github.com/8431/matplotlib/issues/8431"}
| 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:0757f176-ad6b-ad97-e65a-e10c8bdc244d |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | 8D94:18C7E2:25AF0C8:32E0B3C:6A539A1B |
| html-safe-nonce | 8b18a1a2913967d2d33679bb1a9268dd9439e1f42591cd50cb87451fb0880721 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiI4RDk0OjE4QzdFMjoyNUFGMEM4OjMyRTBCM0M6NkE1MzlBMUIiLCJ2aXNpdG9yX2lkIjoiMTcxMTY4OTgwNjYzODE5MzE3OSIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9 |
| visitor-hmac | 6a3bffbbc39de7ee678ac1b2bffc1ed4010b6ad29e3830c2a3480439a2426442 |
| hovercard-subject-tag | issue:219554729 |
| 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/8431/issue_layout |
| twitter:image | https://opengraph.githubassets.com/55739b158c42cfd9e34804017cf79f153fc30763df7725cb33fc1cf0f14a3575/matplotlib/matplotlib/issues/8431 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/55739b158c42cfd9e34804017cf79f153fc30763df7725cb33fc1cf0f14a3575/matplotlib/matplotlib/issues/8431 |
| og:image:alt | I am trying to create a contour plot with the contours filled with hatches and no color. The following example works if I save it to .png but when I save it to .pdf the output is just the axis. imp... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | andres0l1 |
| 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 | canary-1 |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width