I want move the column in a dataframe to last column, I tried
using shift. But this doesn't change the position.
import pandas a pd
df = #input dataframe
df['x'] = df['x'].shift(axis=1)
Error:
raise ValueError(f"No axis named {axis} for object type {cls.__name__}")
ValueError: No axis named 1 for object type Series
Are there other options? Could someone please suggest?