pandas不能在pycharm中使用plot()方法显示图像的解决方法

转自:https://blog.csdn.net/zhaohansk/article/details/50505636
a最近用了pycharm,感觉还不错,就是pandas中Series、DataFrame的plot()方法不显示图片就给我结束了,但是我在ipython里就能画图

以前的代码是这样的

import matplotlib.pyplot as plt
from pandas import DataFrame,Series

Series([4,5,7]).plot()
找了半天
发现只要加个

plt.show()
就可以显示图像了了
import matplotlib.pyplot as plt
from pandas import DataFrame,Series

Series([4,5,7]).plot()
plt.show()

哦了

猜你喜欢

转载自blog.csdn.net/WitsMakeMen/article/details/80932109