I have this current column name:
print(common_nodes_df.columns[0])
('0', '1')
but when I try to change it to:
common_nodes_df.columns[0] = 1
I get this error:
Index does not support mutable operations
What could I do to get around this?
>Solution :
You must replace the whole column names. In your case,
df.columns = [1] + list(df.columns[1:])