I have some plots deployed as a layout using Bokeh Server. For now it is working fine. But when I include the text_font_size
attribute in the label set, it does not work anymore.
labels = LabelSet(x='datetime', y='bool_event', text='Code description', level='glyph',
x_offset=5, y_offset=5, source=ColumnDataSource(df2), render_mode='canvas',
text_font_size=10)
The error I get is the following:
The actual layout is the following one:
You need to give units to your text_font_size. The code should look like this:
labels = LabelSet(x='datetime', y='bool_event', text='Code description', level='glyph',
x_offset=5, y_offset=5, source=ColumnDataSource(df2), render_mode='canvas',
text_font_size="10pt")
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With