Run ❯
Get your
own Python
server
×
Change Orientation
Change Theme, Dark/Light
Go to Spaces
import pandas as pd data = { "age": [50, 40, 30], "qualified": [True, False, False] } df = pd.DataFrame(data) newdf = df.set_axis(["John", "Peter", "Alex"]) print(newdf)
age qualified John 50 True Peter 40 False Alex 30 False