home / github / issue_comments

Menu
  • GraphQL API
  • Search all tables

issue_comments: 477155184

This data as json

html_url issue_url id node_id user created_at updated_at author_association body reactions performed_via_github_app issue
https://github.com/pydata/xarray/issues/1578#issuecomment-477155184 https://api.github.com/repos/pydata/xarray/issues/1578 477155184 MDEyOklzc3VlQ29tbWVudDQ3NzE1NTE4NA== 45180714 2019-03-27T13:31:32Z 2019-03-27T13:32:40Z NONE

I experienced the same issue when using contourf. It was fixed by setting extend='both' in the contourf function, and I got rid of the triangles in my colorbar by setting extendfrac=0 in the colorbar function.

The funny thing is, the code worked just fine yesterday, but when I ran it again today, I encountered this problem.

Non-working code: pcp = ax.contourf(x, y, data, cmap=cmap, levels=bounds, transform=proj, norm=norm) cb = plt.colorbar(pcp, cmap=cmap, pad=0.01, shrink=1, norm=norm, ticks=labels, orientation='horizontal')

Working code: pcp = ax.contourf(x, y, data, cmap=cmap, levels=bounds, transform=proj, norm=norm, extend='both') cb = plt.colorbar(pcp, cmap=cmap, pad=0.01, shrink=1, norm=norm, ticks=labels, orientation='horizontal', extendfrac=0)

I'm pulling data from the NCEP NOMADS server, not sure if that matters, but I've found the data download to be slow and pretty questionable at times.

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  258735262
Powered by Datasette · Queries took 0.96ms · About: xarray-datasette