head, tail, shape, columns
What it is
head/tail show the ends, shape gives (rows, columns), columns lists the names. The cheapest possible orientation.
Why it matters
Row count alone catches a surprising number of mistakes — a join that fanned out, a filter that removed everything, a file that only partly loaded.
In the real world: The first thing an analyst does with a new marketing export: how many rows, which columns, and does it look like what was promised.
df.shape # (10432, 7)
df.columns.tolist() # ['order_id', 'customer_id', ...]
df.head(3)
df.tail(3) # the end often differs: totals rows, truncated writesJudging data quality from head(). Files are frequently sorted, so the first five rows are the least representative sample available.
Practise it: Top N Products by Revenue, The Top Three Per Group, Deterministically