I have several csv files which I want to process using Pandas. The complication is that every file has different header of the 1st column (its data should be read as string) and all other columns' values should be read as numbers.
I want to trim the trailing whitespaces in the values of the first column, but all solutions which I found:
- convert the whole dataframe in string format (this is not desirable)
- need the column name in order to trim only its values (as I said the title of this column is different in every file)
Is there any way in Pandas how to take the 1st column by position and to trim only the trailing spaces of its values?