how to drop duplicate header name columns in dataframe code example Example: python - remove repeted columns in a df df.loc[:,~df.T.duplicated(keep='first')]