3.23每日总结

使用python自带的绘图模块画图时,出现了这个错误:AttributeError: module 'backend_interagg' has no attribute 'FigureCanvas'

问题解决

在文件开头的地方加上这样两行代码:

import matplotlib
matplotlib.use('TkAgg')

这样就能够解决上面提到的问题啦~~~

效果展示一下:

posted @ 2024-03-23 20:46  风·华正茂  阅读(7)  评论(0编辑  收藏  举报