diff --git a/holoviews/operation/datashader.py b/holoviews/operation/datashader.py index 24b6c8bd7a..0b32e4d175 100644 --- a/holoviews/operation/datashader.py +++ b/holoviews/operation/datashader.py @@ -417,6 +417,9 @@ def _apply_datashader(self, dfdata, cvs_fn, agg_fn, agg_kwargs, x, y): val = dfdata[col].values[data] if val.dtype.kind == 'f': val[neg1] = np.nan + elif isinstance(val.dtype, pd.CategoricalDtype): + val = val.to_numpy() + val[neg1] = "-" elif val.dtype.kind == "O": val[neg1] = "-" else: