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
use str.replace: df.columns=df.columns.str.replace('#','')
df.columns=df.columns.str.replace('#','')
You can check this in the documentation.
Instead we can use lamda functions for removing special characters in the column
df2=df1.rename(columns=lambda x:x.strip('*'))