【发布时间】:2014-08-13 20:48:22
【问题描述】:
在下面的设置中,我根据基本示例创建了一个面积图。如何自动甚至以编程方式获取输入的图例。现在我只得到一个带有一个项目“a”和第一种颜色的图例。
from bokeh.plotting import *
...
patches([x2 for a in areas], list(areas.values()), color=colors, alpha=0.8,
line_color=None, legend='a', title="hello chart")
legend().orientation = "top_right" # what other options, may here?
show()
将图例作为值传递给补丁的格式是什么,或者我如何触发 legend() 来显示图中每个项目的项目和颜色?
【问题讨论】:
标签: python legend bokeh legend-properties