☰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

Shift datapoints

Community Support
Ravi_Bhanabhai
Ravi_Bhanabhai

Hi There

I have some categorical data where the x-value is categorical and y-value is numerical. There are chances the y-values will be the same for multiple data-points and if the x-value are the same (likely) then I will have overlap. Is there a way to automatically space out values (along the x-axis) that have similar y-values??

I’m using Circles in Bokeh. I should also note.

For Reference. I’m looking to do spacing similar to this graph in Bokeh

Thank Everyone.

⌁   Link to post
Bryan
Bryan

@Ravi_Bhanabhai If you must cross post on multiple forums, please help reduce the burden on maintainers by always providing the cross-links so that an answer in one place is an answer in all places. (And ideally, make sure yourself that answers are propagated across all places you have asked.)

ref: https://stackoverflow.com/questions/64610353/how-to-space-out-categorical-data-in-bokeh-visualization

There is nothing built in to Bokeh to do actual circle packing like the link, but it’s not clear that that’s what you actually want or need. If you just need a “jitter” transform to apply some random offsets to space things out, that is described here:

If you do need actual circle packing with no overlap for “large” circles (like the link), you would have to compute the positions for things manually.

⌁   Link to post

End of archived discussion · Replies are disabled