Skip to main content
Dressed the naked link, etc.
Source Link
Peter Mortensen
  • 31.1k
  • 22
  • 111
  • 134
df.rename(index=str, columns={'A':'a', 'B':'b'})

pandas.DataFrame.rename

edited body
Source Link
Yog
  • 835
  • 1
  • 10
  • 19
added 6 characters in body
Source Link
eyllanesc
  • 245.7k
  • 19
  • 207
  • 283

pd.rename(index=str,columns={'A':'a','B':'b'})

pd.rename(index=str,columns={'A':'a','B':'b'})

https://pandas.pydata.org/pandas-docs/stable/generated/pandas.DataFrame.rename.html

Source Link
Yog
  • 835
  • 1
  • 10
  • 19
Loading