![](https://img-blog.csdnimg.cn/20201014180756928.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
python
learn_forlife
learn for life
展开
-
SyntaxError: (unicode error) 'unicodeescape' codec can't decode bytes in position 2-3: truncated \UX
当输入的路径如此是f_train=open('C:\Users\Administrator\PycharmProjects\天池\ccf_offline_stage1_train.csv')若出现错误:SyntaxError: (unicode error) ‘unicodeescape’ codec can’t decode bytes in position 2-3: trunca...原创 2018-03-28 20:37:36 · 922 阅读 · 0 评论 -
groupby.agg('sum).reset_index()妙用
@pythondataOut[22]: data key1 key20 1 a one1 2 a two2 3 b one3 4 c three4 5 c onedata.groupby(['key1','key2']).agg('sum').reset_index()O...原创 2018-05-31 22:55:41 · 6087 阅读 · 0 评论