删除行索引重排:
ser.reset_index(drop = True)
df.reset_index(drop = True)
------------------------------------------
直接修列索引:
df = pd.DataFrame(df,columns = ['One','Two','Three'])
删除行索引重排:
ser.reset_index(drop = True)
df.reset_index(drop = True)
------------------------------------------
直接修列索引:
df = pd.DataFrame(df,columns = ['One','Two','Three'])
转载于:https://www.cnblogs.com/xubing-613/p/6119162.html