☰Read-only archive⌕
Looking for help with Bokeh?

This is a read-only archive. Ask questions and join the conversation on GitHub.

Visit Community Support on GitHub →
Archived discussions · Captured October 28, 2026

Update stackers in vbar_stack

Community Support
Snehal_Nair
Snehal_Nair

Hi Community,
I am struggling with updating stackers in stackbar plot in Bokeh. Here is my code, please could you let me know a solution for this ?

fig = figure(
x_range=source_area.data["xaxis_data"]
)

renderers = fig.vbar_stack( 
stackers = top_list_sup,
x="xaxis_data",
source=source_area,
color=colors_area,
legend_label=top_list_sup
)

I would like to update stackers(top_list_sup) dynamically in the callback. Please could you let me know a way to do this ?

Thank you,
Snehal

⌁   Link to post
Bryan
Bryan

Hi @Snehal_Nair More information is needed:

  • is this in a Bokeh server application (python callbacks)? Or in standalone output (CustomJS callbacks)?

  • Are you tying to update the data, while keeping the underlying stacks the same? Or do you want to changes the stacks themselves?

Regardless, vbar_stack is really a convenience method, and as such it trades some flexibility to make things easier to set up. Ultimately, it might just be simplest to remove the plot and replace with a new plot entirely, rather than trying to “update” the existing plot.

⌁   Link to post

End of archived discussion · Replies are disabled