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

A colorbar label doesn't automatically get created for labelled dataset for bokeh backend #5982

Open
ahuang11 opened this issue Nov 12, 2023 · 0 comments
Labels
TRIAGE Needs triaging

Comments

@ahuang11
Copy link
Collaborator

I vaguely remember that the clabel automatically gets created a while back, so I think this might be a regression.

In matplotlib, it automatically shows "z"

import numpy as np
import holoviews as hv
hv.extension('matplotlib')

ls  = np.linspace(0, 10, 400)
x,y = np.meshgrid(ls, ls)
img = hv.Image(np.sin(x)*np.cos(y)+0.1*np.random.rand(400,400), 
               bounds=(-20,-20,20,20)).opts(colorbar=True, xaxis=None, yaxis=None)

hv.Layout([img.relabel(c).opts(cmap=c) for c in ['gray','PiYG','flag','Set1']])
image

Changing it to bokeh, the clabel no longer exists.
image

Another example:

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

ds = xr.tutorial.open_dataset("air_temperature").isel(time=0)
hv.Image(ds, ["lon", "lat"], ["air"]).opts(colorbar=True).redim.label(lat="Latitude", lon="Longitude", air="Air Temperature")
@ahuang11 ahuang11 added the TRIAGE Needs triaging label Nov 12, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
TRIAGE Needs triaging
Projects
None yet
Development

No branches or pull requests

1 participant