pandas dataframe column name: remove special character

后端 未结 2 887
粉色の甜心
粉色の甜心 2021-01-04 17:09

Some joker made a Lotus database/applet thingy for tracking engineering issues in our company. The joke is that the key piece of information was named with a special charac

2条回答
  •  星月不相逢
    2021-01-04 17:42

    use str.replace:
    df.columns=df.columns.str.replace('#','')

    You can check this in the documentation.

提交回复
热议问题