`describe()` is a quick statistical checkup for numeric pandas data. On a Series, it returns count, mean, standard deviation, minimum, quartiles (25%, 50%, and 75%), and maximum together, making it easier to read the overall distribution than calling each aggregation separately. Count excludes `NaN` values, and `50%` is the median. section 1.15
Inspect a numeric Series
A Series of randomly generated values centered near zero can have a mean and median that are close but not identical. Its `describe()` result also shows spread through `std`, the middle half through quartiles, and extreme values through `min` and `max`. After replacing the minimum with five times the maximum, rerunning `describe()` reveals how one extreme value changes the maximum, mean, and standard deviation. section 1.15
df['population'].describe()[['mean', '50%']]
Select a numeric column, summarize it, and then select only `mean` and `50%` when those are the comparison needed. section 3.21
This selective indexing is useful when a question is narrow: `df['population'].describe()[['mean', '50%']]` compares a city-population mean with its median. Removing the 50 largest cities first with `loc[50:, 'population']` produces a second summary, showing how very large values can pull the mean more strongly than the median. section 3.21
comp_sci_universities.join(institutions_df[
['OPEID6', 'TUITIONFEE_OUT']].set_index('OPEID6')).groupby(
'CONTROL')['TUITIONFEE_OUT'].describe()
Chain `groupby('CONTROL')`, select `TUITIONFEE_OUT`, and call `describe()` to compare tuition distributions by university type. section 13.3
`describe()` also fits naturally after data preparation. Once university and tuition data are joined, calling it on the tuition Series answers minimum, median, mean, and maximum in one operation. Calling it after `groupby` produces a table of the same measurements for each group. Rows containing missing summaries can be removed with `dropna()`, and `.T` can transpose the result when statistics are easier to read as rows. section 13.3
Use `describe()` when you need to:
- Get a compact first view of a numeric Series, including missing-value-aware count, center, spread, quartiles, and extremes. section 1.15
- Compare mean and median before and after filtering rows, especially when unusually large or small values may affect the mean. section 3.21
- Summarize one numeric measure separately for groups after selecting, joining, and grouping data. section 13.3

