Python DataFrame 如何删除原来的索引,重新建立索引

删除行索引重排:

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