convert column values to string pandas code example
Example 1: pandas change column to a string
total_rows['ColumnID'] = total_rows['ColumnID'].astype(str)
Example 2: change value to string pandas
mtrx['X.3'] = mtrx['X.3'].astype(str)
Example 3: in dataframe particular column to string
df["fruit"] = df["fruit"].astype("|S")