STAT101 - Introduction to Probability Theory and Statistics
Describing Your Data โ Frequency Distributions, Histograms, Bar/Pie Charts, Stem-and-Leaf, Line Charts & Scatter Diagrams
Chapter 2 is about turning a messy pile of raw numbers into a picture or table that a human can actually understand at a glance. Every method in this chapter answers the same question in a different way: "What does this data look like, and what story is it telling?" The exam will test whether you know which tool to use for which type of data (categorical vs. quantitative, discrete vs. continuous) and whether you can mechanically build a frequency distribution, histogram, or the other charts step by step without making rounding or boundary mistakes.
A frequency distribution is a summary of a set of data that displays the number of observations (the frequency) in each of the distribution's distinct categories or classes.
In plain words: instead of staring at 450 raw numbers, you count how many times each value (or range of values) shows up, and put that count in a table. That's it โ a frequency distribution is just an organized head-count.
| Data Type | Definition | Examples |
|---|---|---|
| Discrete data | Data that can take on a countable number of possible values (usually whole numbers you can list out) | Student ages, number of product categories bought, number of late deliveries per month, number of touchdowns per game |
| Continuous data | Data whose possible values are uncountable and can be any value in an interval | Weight, length, time, response times in seconds |
| Discrete data with many possible outcomes | Technically countable, but so many different values that it behaves like continuous data for graphing purposes | Income, stock prices, GPAs |
If a variable has few distinct values (say, under ~10), build a simple frequency distribution โ one row per actual value (like "0 late deliveries," "1 late delivery," etc.). If a variable is continuous or has many possible values (like income or response time), you must group the data into class intervals first โ this is called a grouped data frequency distribution.
Step 1: List the possible values.
Step 2: Count the number of occurrences at each value (this gives you the
frequency).
Step 3: Compute the relative frequency for each value (see formula below).
Raw data (30 months recorded):
2, 1, 3, 2, 1, 0, 3, 5, 2, 1, 2, 3, 0, 3, 2, 2, 2, 4, 4, 2, 0, 1, 2, 3, 3, 2, 1, 3, 2, 0
| Late Deliveries | Frequency | Relative Frequency |
|---|---|---|
| 0 | 4 | 4/30 = 0.133 |
| 1 | 5 | 5/30 = 0.167 |
| 2 | 11 | 11/30 = 0.367 |
| 3 | 7 | 7/30 = 0.233 |
| 4 | 2 | 2/30 = 0.067 |
| 5 | 1 | 1/30 = 0.033 |
| Total | 30 | 1.000 |
Interpretation: During 13.3% of the months, the company had 0 late deliveries. During 36.7% of the months, they had exactly 2 late deliveries.
Relative Frequency โ the proportion of total observations that fall in a given category or class.
where fi = frequency of the ith value/class, and n = total number of observations.
All relative frequencies in a table must sum to 1.00 (or 100%). If they don't, you made an arithmetic mistake somewhere โ this is a fast way to self-check your work on the exam.
When data is continuous (or discrete with too many distinct values to list one-by-one), we group the data into classes โ non-overlapping intervals that cover the whole range of the data.
Classes must not overlap โ every data value belongs to exactly one class.
Every possible data value must fall into some class โ no gaps.
Classes should (if possible) all span the same distance from their lowest to highest possible value.
Avoid classes with zero frequency โ they waste space and hide the shape of the distribution.
Step 1: Determine the number of classes (k).
Step 2: Establish the class width (W).
Step 3: Determine the class boundaries for each class (the upper and lower limits).
Step 4: Determine the class frequency for each class (count the data points that fall
in each class).
Rule of thumb: use between 5 and 20 classes.
2k ≥ n rule: k is defined as the smallest integer such that 2 raised to the power k is greater than or equal to n (the number of data values).
Just try powers of 2 until you clear n. For n = 72: 26 = 64 (too small), 27 = 128 ≥ 72 ✓. So k = 7 classes. Memorize a few powers of 2: 25=32, 26=64, 27=128, 28=256, 29=512, 210=1024 โ this alone covers almost every exam problem.
Then round the result UP to a convenient ("nicer") number โ never round down, and never round to the nearest value.
Students very often round class width to the nearest whole number instead of always rounding up. If you round down (or even round normally), your classes will not cover the full range of the data and you'll lose the largest value(s). Class width must always round up โ no exceptions.
Data = time (in seconds) to link emergency communication systems in 72 cities. Lowest value = 35, highest value = 1,492.
Step 1 โ Number of classes: n = 72. Find smallest k with 2k ≥ 72. 26=64 (too small), 27=128 ≥ 72. So use 7 classes.
Step 2 โ Class width:
Round up to a "nicer" number: W = 225.
Step 3 โ Class boundaries (starting at 0, using "and under" boundaries, width 225):
| Class Boundaries (seconds) | Frequency |
|---|---|
| 0 and under 225 | 9 |
| 225 and under 450 | 6 |
| 450 and under 675 | 12 |
| 675 and under 900 | 13 |
| 900 and under 1,125 | 14 |
| 1,125 and under 1,350 | 11 |
| 1,350 and under 1,575 | 7 |
| Total | 72 |
Raw data (25 exam scores out of 100):
54, 61, 65, 68, 70, 71, 72, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 87, 88, 90, 91, 95, 99
Step 1 โ Number of classes: n = 25. 24=16 (too small), 25=32 ≥ 25. Use k = 5 classes.
Step 2 โ Class width: High = 99, Low = 54.
Step 3 & 4 โ Full distribution table (class limits are the stated boundaries you write on the table; class boundaries are the true dividing points halfway between the limit of one class and the next, used so classes never overlap; the midpoint is the class average, used later as a stand-in value for every observation in that class):
| Class Limits | Class Boundaries | Midpoint | Frequency (f) | Relative Freq. | Cumulative Freq. | Cumulative Rel. Freq. |
|---|---|---|---|---|---|---|
| 50–59 | 49.5–59.5 | 54.5 | 1 | 0.04 | 1 | 0.04 |
| 60–69 | 59.5–69.5 | 64.5 | 3 | 0.12 | 4 | 0.16 |
| 70–79 | 69.5–79.5 | 74.5 | 10 | 0.40 | 14 | 0.56 |
| 80–89 | 79.5–89.5 | 84.5 | 8 | 0.32 | 22 | 0.88 |
| 90–99 | 89.5–99.5 | 94.5 | 3 | 0.12 | 25 | 1.00 |
| Total | 25 | 1.00 |
Reading the table: 14 students (56%) scored below 79.5; only 3 students (12%) scored in the top class of 90–99.
Cumulative Frequency Distribution: a summary that displays the number of observations with values less than or equal to the upper limit of each class.
Cumulative Relative Frequency Distribution: the proportion (not count) of observations with values less than or equal to the upper limit of each class.
A frequency histogram is a graph of a frequency distribution: the horizontal axis shows the possible values (or class intervals) of the variable, and the vertical axis shows the frequency of each. Bars are drawn as touching rectangles with no gaps between them โ this is what visually distinguishes a histogram from a bar chart.
Below is a simplified visual approximation of a histogram for the "Late Deliveries Per Month" data (0 through 5 deliveries):
A histogram's shape provides information about three things at once:
You may see class boundaries written like [157, 169) or (169, 181]. A square
bracket [ ] means the endpoint is included in that class ("at least/at most"); a
round bracket/parenthesis ( ) means the endpoint is excluded (belongs to the next
class instead). This avoids double-counting a value that sits exactly on a class boundary.
| Choice | Effect |
|---|---|
| Too many classes (narrow class widths) | May yield a jagged distribution with gaps from empty classes; gives a poor/noisy picture of how frequency varies. |
| Too few classes (wide class widths) | May compress variation too much, producing a "blocky" distribution that obscures important patterns. |
A relative frequency histogram looks exactly like a regular histogram, except the vertical axis shows relative frequency (proportions) instead of raw counts. The shape is identical either way โ only the y-axis labels change. This version is useful for comparing two datasets of different sizes, since proportions put them on the same scale.
A frequency polygon is an alternative to the histogram: instead of drawing bars, you plot a point at the midpoint of each class at a height equal to that class's frequency, then connect the points with straight lines. It shows the same shape information as a histogram but as a smooth outline, which makes it easier to overlay two distributions on the same chart for comparison.
All three are graphs built from a frequency distribution, but they answer different questions: a histogram shows the frequency of each class (bars); a frequency polygon shows the same frequencies as a connected line through class midpoints; an ogive shows the running (cumulative) total up to each class's upper boundary. If a question asks "how many/what % fall below a certain value," you want the ogive โ not the histogram.
An ogive is a graph of a cumulative relative frequency distribution. Points are plotted at the upper boundary of each class (x-axis) against the cumulative relative frequency (y-axis), and the points are connected with straight lines. It always rises from left to right, ending at 1.0 (100%).
Use an ogive when a question asks something like "what percentage of observations are below X?" โ you can read that answer directly off the curve, which is much faster than re-adding cumulative frequencies by hand.
A joint frequency distribution summarizes data that is characterized by more than one variable at the same time (e.g., payment method AND which parking garage a customer used). It can be built for qualitative or quantitative variables.
Steps: (1) Obtain the data. (2) Construct the rows and columns of the table (one variable's categories become rows, the other's become columns). (3) Count the joint occurrences for every row/column combination and place them in the matching cell. (4) Calculate row totals and column totals (these are called marginal frequencies).
| Garage 1 | Garage 2 | Total | |
|---|---|---|---|
| Charge | 40 | 20 | 60 |
| Cash | 10 | 10 | 20 |
| Total | 50 | 30 | 80 |
Reading a cell: 40 customers paid by charge card AND used Garage 1. Reading a margin: 60 customers total paid by charge (regardless of garage); 50 customers total used Garage 1 (regardless of payment method).
Section 2.1's tools (frequency distributions, histograms, ogives) are mainly for quantitative data. Section 2.2 introduces the standard tools for qualitative (categorical) data โ bar charts and pie charts โ plus the stem-and-leaf diagram, a hybrid table/graph for quantitative data.
A bar chart is a graphical representation of a categorical data set in which a rectangle (bar) is drawn over each category or class. The length/height of each bar represents the frequency, percentage, or other measure associated with that category. Bars can be vertical or horizontal, and unlike a histogram, there are gaps between the bars because the categories are not on a continuous numeric scale.
Simplified bar chart demo โ 2015 New Car Sales (top companies, in millions):
When comparing two groups across the same categories (e.g., male vs. female starting salaries by year), use a side-by-side (clustered) bar chart โ one pair of bars per category, color-coded by group. This makes direct comparison easy without needing two separate charts.
A pie chart is a graph in the shape of a circle used to show visually the parts of a total. The circle is divided into "slices" corresponding to categories, and the size (central angle) of each slice is proportional to the magnitude of that category relative to the whole.
Steps to construct: (1) Define the categories. (2) For each category, compute its proportion of the total. (3) Draw one slice per category sized proportionally to that category's share of the total (proportion × 360°).
Simplified pie chart demo โ Golf Equipment Impact survey:
Golf Ball โ 27%
Club Head Material โ 22%
Shaft Material โ 21%
Club Head Size โ 21%
Don't Know / Other โ 9%
A classic exam trap: a table shows "Tax Dollars Per Student" at four different universities (e.g., $7,143, $5,900, $6,320, $5,410). Someone builds a pie chart from these numbers โ but this is wrong, because a pie chart implies the slices are parts of one meaningful total (they should add up to something whole, like "100% of the budget"). These four numbers are separate, independent averages that don't sum to any meaningful total โ a bar chart should be used instead to compare them side by side.
A stem-and-leaf diagram is a display that splits each data value into two parts: the leaf (the rightmost/units digit) and the stem (all digits to the left of the units place). It works like a sideways histogram but keeps every original data value visible.
Steps to construct:
Step 1: Sort the data from low to high.
Step 2: Split each value into a stem and a leaf (leaf = units digit; stem = everything
else). Example: for 113, the stem is 11 and the leaf is 3.
Step 3: List all possible stems from lowest to highest (even ones with no data
yet).
Step 4: Itemize the leaves from lowest to highest, placing each leaf next to its
matching stem.
Data: 44, 53, 57, 59, 62, 62, 63, 66, 67, 69, 72, 76, 79, 80, 81, 85, 87, 88
| Stem | Leaves |
|---|---|
| 4 | 4 |
| 5 | 3 7 9 |
| 6 | 2 2 3 6 7 9 |
| 7 | 2 6 9 |
| 8 | 0 1 5 7 8 |
Reading it: row "6 | 2 2 3 6 7 9" represents the values 62, 62, 63, 66, 67, 69. Turn the diagram 90° counter-clockwise and it looks exactly like a histogram โ except you can still read off every exact original value.
Use a stem-and-leaf diagram when your dataset is small/medium and you want to preserve the exact original values while still seeing the shape of the distribution. Use a histogram (with grouped classes) when the dataset is large โ a stem-and-leaf diagram becomes unreadable with hundreds of values because each stem row gets too long.
A line chart is a two-dimensional chart showing time on the horizontal axis and the variable of interest on the vertical axis. It is used specifically to display time-series data โ values of a single variable recorded at successive points in time โ and to visualize trends.
Steps to construct: (1) Identify the time-series variable and determine its range of values and the range of time periods covered. (2) Construct the horizontal axis for time periods, and a vertical axis scaled to the range of values. (3) Plot the points and connect them with straight lines.
When comparing two variables with very different scales (e.g., Sales in the tens of thousands of dollars vs. Profit in the thousands), plot them on the same chart with two different vertical axes (one on the left, one on the right) rather than squeezing both onto one axis โ otherwise the smaller-scale variable will look like a flat line near zero and you'll miss its trend entirely.
A scatter diagram (or scatter plot) is a two-dimensional graph of plotted points showing the relationship between two quantitative variables. Unlike a line chart, points are never connected โ each point simply represents one paired observation.
Dependent variable (y-axis): the variable whose values are thought to be a function
of (caused/predicted by) another variable.
Independent variable (x-axis): the variable thought to impact the values of
the dependent variable.
Steps to construct: (1) Identify the dependent and independent variable. (2) Collect paired values for the two variables. (3) Construct the horizontal axis using the independent variable and the vertical axis using the dependent variable. (4) Plot the points โ do not connect them.
| Pattern | What It Looks Like | Meaning |
|---|---|---|
| Positive linear | Points trend upward, roughly along a straight line, from lower-left to upper-right | As x increases, y tends to increase |
| Negative linear | Points trend downward, roughly along a straight line, from upper-left to lower-right | As x increases, y tends to decrease |
| Curvilinear | Points follow a curved (non-straight) pattern โ e.g., rises then falls, or bends | A relationship exists but is not a straight line |
| No relationship | Points scattered with no visible pattern, or forming a flat horizontal cloud/band | Changes in x tell you nothing about y |
| Volume per Day | Cost per Day |
|---|---|
| 23 | $125 |
| 33 | $160 |
| 42 | $170 |
| 55 | $195 |
| 60 | $200 |
Interpretation: As Volume per Day (independent variable, x-axis) increases, Cost per Day (dependent variable, y-axis) also increases in a fairly straight-line pattern โ this is a positive linear relationship. It makes sense: producing more units costs more.
Always ask "which variable is being caused by or predicted from the other?" Cost depends on volume (not the reverse), so Cost is dependent (y-axis) and Volume is independent (x-axis). Swapping the axes doesn't change the math, but it will cost you marks if the question specifically asks you to identify which is which.
A Pareto chart is a special type of bar chart used to separate the "vital few" from the "trivial many." Bars represent categorical values and are always organized from highest to lowest (left to right), making it immediately obvious which few categories account for most of the problem.
| Downtime Cause | Minutes |
|---|---|
| Waiting on Material | 400 |
| Maintenance | 280 |
| Operator Error | 160 |
| Broken Belt | 135 |
| Electric Issue | 90 |
| Other/Miscellaneous | 40 |
Reading it: "Waiting on Material" and "Maintenance" together account for 680 of the 1,105 total downtime minutes (~61.5%) โ these are the "vital few" causes a manager should tackle first, rather than spreading effort evenly across all six categories.
A Pareto chart is a bar chart โ the only difference is the mandatory descending sort order by frequency/magnitude. If a question shows you a bar chart already sorted from tallest to shortest bar and asks "what kind of chart is this," and it's built to highlight the dominant few causes of a categorical problem, the expected answer is Pareto chart, not just "bar chart."
| Chart/Table Type | Data Type | Best Used For |
|---|---|---|
| Frequency Distribution / Histogram | Quantitative (discrete or grouped continuous) | Showing the shape, center, and spread of a single numeric variable |
| Ogive | Quantitative (cumulative) | Reading off "what % of values are below X" |
| Bar Chart | Qualitative / categorical | Comparing frequencies or magnitudes across distinct categories |
| Pareto Chart | Qualitative / categorical | Identifying the few categories responsible for most of a total (quality control) |
| Pie Chart | Qualitative / categorical | Showing how categories make up parts of one meaningful whole (must sum to 100%) |
| Stem-and-Leaf Diagram | Quantitative (small/medium n) | Seeing distribution shape while preserving every exact data value |
| Line Chart | Quantitative, time-based | Showing a trend of one variable over time |
| Scatter Diagram | Two quantitative variables | Showing the relationship (or lack thereof) between two numeric variables |
Using a pie chart or bar chart interchangeably without checking whether the data is truly "parts of a whole" (pie) vs. simply "independent category comparisons" (bar) is the single most common conceptual error in this chapter. Also remember: histograms have no gaps between bars (continuous data), while bar charts do have gaps (categorical data) โ this is a favorite true/false exam question.
1. A company wants to know how many of each department's employees (Sales, HR, IT, Finance) work overtime. Which chart is most appropriate?
2. A dataset has n = 50 observations. Using the 2k ≥ n rule, how many classes should you use?
3. The largest value in a dataset is 187 and the smallest is 22. You decide to use 6 classes. What is the class width (before rounding to a "nicer" number)?
4. Which statement about histograms and bar charts is TRUE?
5. A scatter diagram shows points that steadily rise from the lower-left to the upper-right, following a straight-line pattern. This indicates:
6. Which chart is specifically designed to separate the "vital few" categories from the "trivial many," sorting bars from highest to lowest?
7. In a stem-and-leaf diagram, the value 138 would be split into which stem and leaf?
8. A researcher plots "hours studied" (x-axis) against "exam score" (y-axis) for 40 students. What kind of chart is this, and which variable is dependent?
Q1. The following 20 values represent the number of minutes 20 customers waited in
line at a bank:
2, 5, 3, 8, 6, 4, 7, 9, 3, 5, 6, 2, 4, 8,
10, 5, 6, 3, 7, 4
Construct a full grouped frequency distribution (using the 2k ≥ n rule for number of classes, and rounding class width up to a nicer number). Include class limits, frequency, relative frequency, and cumulative frequency.
Answer:
n = 20. Find smallest k with 2k ≥ 20: 24 = 16 (too small), 25 = 32 ≥ 20. Use k = 5 classes.
Largest value = 10, smallest = 2. W = (10 − 2)/5 = 1.6 → round up to a nicer width, W = 2.
Sorted data: 2, 2, 3, 3, 3, 4, 4, 4, 5, 5, 5, 6, 6, 6, 7, 7, 8, 8, 9, 10
| Class Limits | Frequency | Relative Frequency | Cumulative Frequency |
|---|---|---|---|
| 2–3 | 5 | 0.25 | 5 |
| 4–5 | 6 | 0.30 | 11 |
| 6–7 | 5 | 0.25 | 16 |
| 8–9 | 3 | 0.15 | 19 |
| 10–11 | 1 | 0.05 | 20 |
| Total | 20 | 1.00 |
Q2. A survey asks 100 shoppers which payment method they used: Cash (35), Credit Card (45), Debit Card (15), Mobile Pay (5). Should this be shown as a pie chart or a bar chart? Justify your answer, and state what percentage each slice/bar would represent.
Answer: Either works, but a pie chart is especially appropriate here because the four categories are parts of one meaningful whole โ all 100 shoppers, no overlaps, covering 100% of the surveyed group. Percentages: Cash = 35/100 = 35%, Credit Card = 45/100 = 45%, Debit Card = 15/100 = 15%, Mobile Pay = 5/100 = 5%. These sum to 100%, confirming a pie chart is valid (unlike the earlier Idaho tuition example, which did NOT sum to a meaningful total).
Q3. Explain, using the "vital few vs. trivial many" idea, why a Pareto chart would be more useful than a plain (alphabetically sorted) bar chart for a manager investigating the biggest sources of customer complaints.
Answer: An alphabetically sorted bar chart forces the reader to scan every bar to figure out which complaint categories matter most. A Pareto chart sorts bars from highest to lowest frequency, so the largest contributors appear first, immediately visible on the left. This lets the manager instantly identify the "vital few" complaint types that account for the majority of the problem (often following something close to an 80/20 pattern) and prioritize fixing those first, rather than spending equal effort across all categories including rare, low-impact ones (the "trivial many").
| Term | Definition |
|---|---|
| Frequency distribution | A summary of a data set that displays the number of observations in each distinct category or class |
| Discrete data | Data that can take on a countable number of possible values |
| Continuous data | Data whose possible values are uncountable and can be any value in an interval |
| Class limits | The stated lower and upper values that define a class as written in the frequency table |
| Class boundaries | The true dividing points between classes (halfway between the upper limit of one class and the lower limit of the next), ensuring classes don't overlap |
| Class midpoint | The average of a class's lower and upper boundary; used to represent all values in that class |
| Class width | The distance spanned by each class; computed as (largest value โ smallest value) / number of classes, then rounded up |
| Relative frequency | The proportion of total observations falling in a given class (frequency รท n) |
| Cumulative frequency | The number of observations less than or equal to the upper limit of a given class |
| Cumulative relative frequency | The proportion of observations less than or equal to the upper limit of a given class |
| Histogram | A graph of a frequency distribution using touching bars (no gaps) over a numeric scale |
| Frequency polygon | A line graph connecting the midpoints of each class at their frequency height, used as an alternative to a histogram |
| Ogive | A graph of the cumulative relative frequency distribution, plotted at each class's upper boundary |
| Joint frequency distribution | A table summarizing data characterized by two or more variables simultaneously, with row/column totals (marginal frequencies) |
| Bar chart | A graph using separate (gapped) bars to represent the frequency or magnitude of categorical data |
| Pie chart | A circular graph divided into slices proportional to each category's share of a meaningful total |
| Pareto chart | A special bar chart with categories sorted from highest to lowest, used to identify the "vital few" causes |
| Stem-and-leaf diagram | A display splitting each value into a stem (leading digits) and leaf (units digit) to show distribution shape while preserving exact values |
| Line chart | A two-dimensional chart with time on the horizontal axis, used to display time-series trends |
| Scatter diagram | A two-dimensional plot of unconnected points showing the relationship between two quantitative variables |
| Dependent variable | The variable whose values are thought to be a function of (caused/predicted by) another variable; plotted on the y-axis |
| Independent variable | The variable thought to impact the values of the dependent variable; plotted on the x-axis |
| Positive relationship | As the independent variable increases, the dependent variable also tends to increase |
| Negative relationship | As the independent variable increases, the dependent variable tends to decrease |
| Curvilinear relationship | A relationship between two variables that follows a curved, non-straight-line pattern |