【发布时间】:2018-08-09 06:51:40
【问题描述】:
我正在尝试使用 Python 创建散景条形图。 data2 是值
from bokeh.plotting import figure, output_file, show,hplot
from bokeh.charts import Bar
data2=[65.75, 48.400000000000006, 58.183333333333337, 14.516666666666666]
bar = Bar(values=data2,xlabel="beef,pork,fowl,fish",ylabel="Avg consumtion", width=400)
show(bar)
错误
TypeError: Bar() takes at least 1 argument (1 given)
我在这里做错了什么?
【问题讨论】: