I am trying to replace "," by "" for 80 columns in a panda dataframe.
I have create a list of the headers to iterate:
headers = ['h1', 'h2', 'h3'... 'h80']
and then I am using the list to replace multiple columns string value as bellow:
dataFrame[headers] = dataFrame[headers].str.replace(',', '')
Which gave me this error: AttributeError: 'DataFrame' object has no attribute 'str'
When I try the same on only one header it works well, and I need to use the str.replace because the only replace method does sadly not replace the ",".