I would like to change the dataframe such that the values in column 0 are new columns with there repective values coming from same index at column 1 for example for column name Agreement Number its value would be 59598840.So basically transposing this dataframe Could anybode tell how to do it?
CodePudding user response:
Try:
df.set_index(0).transpose()
This sets your first column as an index and transposes a dataframe to give you desired column structure.