pandas 保存为xls时报错误:AttributeError OpenpyxlWriter object has no attribute save Did you mean _save 如何解决
这个错误是由于pandas版本的问题引起的。在旧版本的pandas中,使用to_excel()方法保存为xls文件时会报这个错误。
解决方法是升级pandas版本到0.25.0及以上。你可以使用以下命令升级pandas:
pip install --upgrade pandas
升级后,再次尝试保存为xls文件,应该就不会再报这个错误了。
原文地址: https://www.cveoy.top/t/topic/iUAv 著作权归作者所有。请勿转载和采集!