Need specific columns or rows? Pandas makes selection intuitive and fast:
# Single column (Series)
df['name']
# Multiple columns (DataFrame)
df[['name', 'age', 'sales']]
# Row selection with .loc (label-based)
df.loc[0:5] # Rows 0 to 5
df.loc[df['sales'] > 1000] # Conditional
# .iloc (position-based)
df.iloc[0:5, 1:4] # Rows 0-4, columns 1-3
Next up 👉 Filtering and Querying
