home / github / issue_comments

Menu
  • GraphQL API
  • Search all tables

issue_comments: 485928903

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/2915#issuecomment-485928903 https://api.github.com/repos/pydata/xarray/issues/2915 485928903 MDEyOklzc3VlQ29tbWVudDQ4NTkyODkwMw== 6628425 2019-04-23T18:50:19Z 2019-04-23T18:50:19Z MEMBER

Thanks @fabienpaulot -- this could probably use a better error message. The arguments passed to x and y must be dimension or coordinate names of the DataArray rather than DataArrays themselves. In your case you can assign xcntr and ycntr as coordinates of test and then plot:

python test = test.assign_coords(x=xcntr.rename({'nxp': 'xh', 'nyp': 'yh'}), y=ycntr.rename({'nxp': 'xh', 'nyp': 'yh'})) test['nh4_stf'].plot.contourf(x='x', y='y', ax=ax, transform=ccrs.PlateCarree())

The renaming is necessary so the dimension names match that of test.

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