Holoviews: Error bars not working for categorical axis with bokeh

Created on 22 Sep 2020  路  3Comments  路  Source: holoviz/holoviews

ALL software version info

holoviews = 1.13.3
python = 3.6.10
bokeh = 2.2.1

on MacOs 10.14.6

Description of expected behavior and the observed behavior

Expected: Error bars are shown for categorical values

Error bars are not shown, issue should already be resolved:
https://github.com/holoviz/holoviews/issues/1470

Complete, minimal, self-contained example code that reproduces the issue

%%opts ErrorBars (line_width=2 line_color='darkblue')
%%opts Points    [invert_axes=False] (color='darkred' size=6)
import holoviews as hv
import numpy as np

x=['a','b','c','d','e']
points = [(x[i], 5*np.random.rand()) for i in range(5)]
errors = [points[i]+(np.random.rand()/2,) for i in range(5)]

h1 = hv.Points(points)
h2 = hv.ErrorBars(errors)
h2*h1

Screenshots or screencasts of the bug in action

image

bug

All 3 comments

Based on the issue you linked to, this definitely sounds like a regression (since it looks like it was fixed in 2017!)

Hello, I have just stambled upon this error. Is there any workaround I can use before it is fixed?

Hola,
Seems to be related to categorical data in X axis; was facing the issue today and at the time I changed the X axis to numerical, the error bars start working. Need to show the categorical values in the x axis; any suggestion for workaround more than welcome.

Look the new definition of pointsvariable.

%%opts ErrorBars (line_width=2 line_color='darkblue')
%%opts Points    [invert_axes=False] (color='darkred' size=6)

x=['a','b','c','d','e']
points = [(i,5*np.random.rand()) for i in range(5)]
#[(x[i], 5*np.random.rand()) for i in range(5)]
errors = [points[i]+(np.random.rand()/2,) for i in range(5)]

h1 = hv.Points(points)
h2 = hv.ErrorBars(errors)
h2*h1
Was this page helpful?
0 / 5 - 0 ratings

Related issues

jlstevens picture jlstevens  路  6Comments

ceh-creare picture ceh-creare  路  5Comments

claresloggett picture claresloggett  路  5Comments

ahuang11 picture ahuang11  路  5Comments

ahundt picture ahundt  路  6Comments