Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Xarray non dimensional kdims #6132

Draft
wants to merge 5 commits into
base: main
Choose a base branch
from
Draft

Xarray non dimensional kdims #6132

wants to merge 5 commits into from

Conversation

hoxbro
Copy link
Member

@hoxbro hoxbro commented Feb 26, 2024

Fixes #6131

image

import numpy as np
import holoviews as hv
import xarray as xr
hv.extension("bokeh")

da = xr.DataArray(np.arange(6).reshape(6,1), dims=["x", "stat"], coords={"x": np.arange(6), "stat": ["mean"], "x2": ('x', np.arange(6)/6)})
hv.Curve(da, kdims="x2", vdims="stat")

TODO:

  • Add test
  • Check if this is the best way to do it

@hoxbro hoxbro added the type: bug Something isn't correct or isn't working label Feb 26, 2024
@hoxbro hoxbro marked this pull request as draft February 26, 2024 16:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type: bug Something isn't correct or isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Support using xarray non-dimensioned coordinates as explicit kdims.
1 participant