Open MarcSkovMadsen opened 1 year ago
Thanks for the reproducible example!
@MarcSkovMadsen could you please not assign milestones and labels on hvPlot repo? I've been trying to careful curate them and I'm still in the process of doing so. I'll let you know once this is done and will make it clearer how it should be done. Thanks!
Same problem arises when using heterogeneous data column using hover_cols : df.hvplot(y='numeric',hover_cols=['heterogeneous'])
with df:
quick user side fix using df = df.assign(heterogeneous=df.heterogeneous.astype('str'))
I just came across a similar situation using holoviews and had troubles debugging. It seem the issue above is not limited to hvplot (but I guess also the traceback indicates that), and not limited to when the hetereeogenous columns is actually used. I am on the following versions:
Your code example @MarcSkovMadsen converted to holoviews:
import pandas as pd
import holoviews as hv
hv.extension('bokeh')
df = pd.DataFrame({
"x": [1,2],
"y": [3,4],
"text": [0, "+1"],
})
hv.Points(df, ["x", "y"])
even though the heterogenous column is not part of the picture.
while if one exclude the column with heterogenous info entirely then there is no error.
hv.Points(df[["x", "y"]], ["x", "y"])
hv.Points(df, ["x", "y"])
use the text column as the vdims. You can see this by: print(hv.Points(df, ["x", "y"]))
hvplot==0.8.1
A colleague of mine was trying to add labels to her plot. She got an exception that was hard to find the cause of. The problem was that she was using heterogenous data as text labels.
Here is a minimum, reproducible example.