用了plt.show(),仍然没有出现图形,提示信息:
<Figure size 432x288 with 1 Axes>
过程:
原因猜测:
你的python解释器有多个,导致pycharm识别混乱,我是安装了python3.7和anaconda的,python3.7里没有安装matplotlib,anaconda装了matplotlib。
问题解决:
pip install sklearn -i https://mirrors.aliyun.com/pypi/simple
import matplotlib
matplotlib.use('TkAgg')
继续画图,画图结束后:
plt.show()
本文地址:https://blog.csdn.net/CSDNsue/article/details/107313778
如对本文有疑问, 点击进行留言回复!!
从零开始的PYTHON3摸鱼(二)windows如何运行python,编辑器选择
网友评论