# get the column names and move the last column to the front cols = list(df.columns) cols = [cols[-1]] + cols[:-1] # reindex the dataframe with the new column order df = df.reindex(columns=cols)
Preview:
downloadDownload PNG
downloadDownload JPEG
downloadDownload SVG
Tip: You can change the style, width & colours of the snippet with the inspect tool before clicking Download!
Click to optimize width for Twitter