You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
There is an error in plotting coordinates with multiple dimensions using xarray.hvplot. xarray.plot (and also matplotlib) have the correct behavior. Here is some code to demonstrate the issue.
A simple fix could be to do a ones_like broadcast within hvplot when coordinates don't match, like presented in the last example, to ensure coordinates have the same size and shape.
The text was updated successfully, but these errors were encountered:
There is an error in plotting coordinates with multiple dimensions using xarray.hvplot. xarray.plot (and also matplotlib) have the correct behavior. Here is some code to demonstrate the issue.
Matplotlib does the right thing using the raw numpy arrays:
xarray.plot also does the right thing:
xarray.hvplot fails:
Making a dummy 2d coordinate for
x
fixes things, and shows the functionality that users probably expect:A simple fix could be to do a
ones_like
broadcast within hvplot when coordinates don't match, like presented in the last example, to ensure coordinates have the same size and shape.The text was updated successfully, but these errors were encountered: