前言
今天用pyecharts画图的时候,发现 from pyecharts import Bar 失败,直接报错 cannot import name 'Bar'
解决方法
事先说明,引起这个问题是版本引起的,看了下官方的github发现的。你可以修改对应的版本
1- 降低版本:支持 Python2.7,3.4+
pip install pyecharts==0.5.11
2- 升级版本:仅支持 Python3.6+
pip install wheel
pip install pyecharts==0.1.9.4 或则 pip install pyecharts -U
pip install pyecharts-snapshot
参考链接