How to make legend into dropdown?
In Bokeh, the widget is called Select. There's no function like legend_to_select if that's what you want. But you can just avoid creating the legend at all and create the select widget manually. You will have to manually hook it up to the glyphs via a CustomJS callback and it won't support displaying glyphs since it supports only text. If you require displaying glyphs as well, you will have to create a custom Bokeh model that extends Select and overrides the item rendering mechanism.
Currently, I am working on a map visualization project using Bokeh.
Because the legend of the map is too many, the legend crowded the map.
Is there any way to make the legend into something like a dropdown menu in Bokeh?
Thank you