Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PYTHON

df = df.reset_index(level=0)

How to convert index of a pandas dataframe into a column
df = df.reset_index(level=0)
df['index1'] = df.index
Source by pandas.pydata.org #
 
PREVIOUS NEXT
Tagged: #df
ADD COMMENT
Topic
Name
9+2 =