问题描述:
利用PyCharm中Matplotlib绘图时,出现AttributeError: module ‘backend_interagg’ has no attribute 'FigureCanvas’错误。

在这里插入图片描述

问题原因及解决方法:
matplotlib版本过高,需要降低matplotlib版本。
注:现有matplotlib版本为3.6.0,将其降低为3.5.0

pip uninstall matplotlib
pip install matplotlib==3.5.0

至此,问题得以解决!

更多推荐