我是靠谱客的博主 柔弱冬天,这篇文章主要介绍Python报【Falling back to the ‘python‘ engine because the ‘c‘ engine does not support skipfooter】的解决方案,现在分享给大家,希望可以做个参考。
如题,使用pandas读取txt数据时,报如下警告:
D:Program Filespython3.7libsite-packagespandasutil_decorators.py:311: ParserWarning: Falling back to the ‘python’ engine because the ‘c’ engine does not support skipfooter; you
can avoid this warning by specifying engine=‘python’.
return func(*args, **kwargs)
要不说python友好呢,都直接给出了解决方案,在参数列表添加engine='python',如下:
# 报错前
data = pd.read_table("txt.txt", header=None, sep = 't', skiprows=1, skipfooter=1)
# 报错后
data = pd.read_table("txt.txt", header=None, sep = 't', skiprows=1, skipfooter=1,engine='python')
最后
以上就是柔弱冬天最近收集整理的关于Python报【Falling back to the ‘python‘ engine because the ‘c‘ engine does not support skipfooter】的解决方案的全部内容,更多相关Python报【Falling内容请搜索靠谱客的其他文章。
本图文内容来源于网友提供,作为学习参考使用,或来自网络收集整理,版权属于原作者所有。
发表评论 取消回复