Before you start
You will be able to
- Recognise from a scatterplot when a relationship is curved, has a threshold or is U-shaped, and explain what Pearson’s r then does and does not describe.
- Calculate correlations within ranges of x and with a transformed x (a log or a hinge at a threshold) to show how the strength of a link changes along its range.
- Explain why restricting the range of x, for example to summer days or to one café’s weekdays, usually shrinks r, and estimate the effect with the range-restriction formula.
- Estimate how unreliable measurements attenuate a correlation, and say what the correction for attenuation assumes.
- Choose between Pearson’s r, Spearman’s ρ and a plot with a written description for a curved relationship.
Review first
- Scatterplots — Reading the form of a relationship (linear, curved, clustered) from a scatterplot.
- Rank correlation — Spearman’s ρ and the difference between a monotonic and a linear relationship.
- Outliers and influence — How a few points can move r; this lesson looks at what the shape of the whole cloud does.
- Skewed data and transformations — Log transformations and why they need positive values.
Fictional case A fictional coffee business founded by Ana Lim. It starts as a catering and barista-training service, opens its own cafés and an online shop for beans, and plans a canned cold brew.
The idea
Fictional case
Ana plans the iced-drink stock for next summer from the café log. Across the 612 café-days, the day’s high temperature and the share of drinks served iced have r = 0.940, about as strong as correlations in business data get. Her summer manager, looking only at June to August, finds r = 0.841, and only 0.657 for July. “Temperature hardly matters in high summer,” he says. Who is right?
r measures closeness to a line
Pearson’s r answers one precise question: how closely do the points cluster around a straight line? It does not measure how strongly y depends on x in general. When the relationship is a straight line with even scatter, the two ideas coincide. When it is curved, has a threshold, or rises and then falls, r can mislead in either direction: it can be high while hiding the shape, or close to zero while the link is strong.
The iced-drink share is a curve. On cold days it barely moves: 7.2% of drinks are iced on days below 50°F and 10.4% between 50 and 55°F. Between about 60 and 75°F it climbs fast, by 13 to 16 percentage points for every 5°F. Above 80°F it levels off again near 80%, because some customers want hot coffee whatever the weather. The shape is an S. Because the curve rises all the way, it is a monotonic relationship, and a straight line still fits it fairly well: r = 0.940, and Spearman’s ρ, which needs only a consistent direction, is a little higher at 0.957.
The number hides what matters for stock planning: the same 5°F rise changes the iced share by about 3 percentage points on the coldest days and by 13 to 16 on mild ones. A single r can’t say that. A scatterplot, or a table of the iced share by temperature band like the one in the In depth section, can.
Thresholds: when r understates the link
The morning peak tells a sharper story. Ana divides the number of peak transactions by the barista hours rostered for the peak, giving the peak load: the transactions each barista hour has to serve. Load and the average peak wait have r = 0.830. But the plot is not a cloud around a line. It is a threshold effect: flat at about 1.6 to 1.8 minutes for loads up to 7, then rising ever more steeply, to an average of 5.8 minutes when the load passes 10.
Here r understates the link. On the 169 café-days with a load of 7 or less, load and wait are unrelated (r = −0.10); on the 443 days above 7, r = 0.93. Measured against the shape the data actually follow, the squared distance above 7, the correlation is 0.980. The relationship is close to a law: keep the load under about seven transactions per barista hour and waits stay short. An r of 0.83, read as “strong but loose”, would miss that.
U-shapes: when r says nothing
A relationship that rises and then falls, or falls and then rises, can have r close to zero however strong it is. The hotel in the figure gets complaints when rooms are too cold and when they are too warm. Across its eleven settings r = 0.00, yet complaints are almost perfectly predictable from the distance between the setting and 19.5°C. A correlation of zero means no straight-line relationship, not no relationship.
Looking at part of the range
Back to the summer manager. Restricting the data to June to August cuts out the cold days, so temperatures run only from 67 to 94°F, with a standard deviation of 6.4°F instead of 15.0°F. With less variation in x, the same scatter around the curve is a larger share of what is left, and r shrinks: from 0.940 for the year to 0.841 for summer and 0.657 for July. July also sits on the flat top of the S, where warmer days add little. Temperature still matters in July, just less than in May, and over a narrower range. Both of them are describing the data correctly; they are describing different data.
In depth
Reading the curve in bands
A quick way to see a curve’s shape without fitting anything is to group x into bands and average y within each band. The table does this for the iced share; with 612 café-days every band has at least 50 days, so each average is reasonably stable.
| High (°F) | Café-days | Mean iced share |
|---|---|---|
| below 50 | 124 | 7.2% |
| 50–54 | 58 | 10.4% |
| 55–59 | 58 | 16.1% |
| 60–64 | 70 | 24.9% |
| 65–69 | 58 | 40.9% |
| 70–74 | 62 | 54.4% |
| 75–79 | 60 | 66.3% |
| 80–84 | 70 | 76.0% |
| 85 and above | 52 | 79.5% |
Read down the last column: small steps at the top of the table, large steps in the middle, small steps again at the bottom. A straight line through these averages would overstate the rise on cold days and on hot days and understate it in between. The departures from a fitted line, its residuals, would show the same pattern; B06 plots residuals properly.
Strength along the range: the threshold
| Load | Café-days | Mean peak wait (min) |
|---|---|---|
| under 7 | 169 | 1.63 |
| 7–8 | 103 | 1.73 |
| 8–9 | 91 | 2.17 |
| 9–10 | 103 | 3.06 |
| 10 or more | 146 | 5.85 |
Correlations within ranges confirm what the bands show: r = −0.10 for loads of 7 or less and 0.93 above 7. A hinge transformation makes the shape explicit: is zero below the threshold c and rises one for one above it. With c = 7, the hinge has r = 0.917 with the wait; squaring it, to allow for the wait rising ever faster, gives 0.980. That 0.98 is closer to the truth about this link than 0.83.
Two cautions. First, the threshold of 7 came from looking at these data, so a correlation with a hinge chosen to fit them flatters the fit; it describes this year’s log well and should be checked on new data. Second, Spearman’s ρ is 0.867 here, a little above r, because ρ rewards any steady rise, but it is no better at describing a flat stretch followed by a steep one. For a threshold, report where it is and how the slope changes, not only a coefficient.
U-shapes and turning points
For a symmetrical U, the positive products of z-scores on one side cancel the negative ones on the other, so r comes out near zero. In the hotel’s data, r is −0.97 on the cold side (settings up to 19.5°C) and +0.96 on the warm side; together, 0.00. Spearman’s ρ, which needs a consistent direction, fails too (−0.03). The fix is to measure against the shape: complaints have r = 0.97 with the distance from 19.5°C and 0.999 with its square. As with the threshold, the turning point was read from the data, so state it as a finding to confirm.
Transformations in outline
Some curves straighten under a transformation. A log transformation turns equal ratios into equal differences, which suits relationships in which y grows by a percentage when x grows by a percentage. In twelve fictional towns, the number of cafés rises with population but more and more slowly: r = 0.950 on the raw values, 0.994 on the logs of both. Logs need positive values, so they can’t be used directly on Lantern’s rainfall, which is zero on most days.
Spearman’s ρ is 0.993 for the towns, on raw values or logs alike, because a log keeps every value in the same order. That is a useful property: a rank correlation doesn’t depend on which monotonic transformation you choose, while Pearson’s r does. Fitting a curve after a transformation, and interpreting its slope, belongs to B06.
Restricted range
Range restriction means the data cover only part of the values the variable takes. If the relationship is a straight line with even scatter, and the restriction is on x alone, then shrinking the standard deviation of x from S to s changes r in a predictable way. With , the correlation over the full range would be , where is the correlation in the restricted data. The formula card gives the details.
For the summer days, k = 15.0 ÷ 6.4 ≈ 2.3 and the formula turns the summer r of 0.841 into 0.964, against 0.940 actually observed. It overshoots because the relationship is an S, not a line, and the scatter is not even. The formula is a guide to how much restriction matters, not a way to recover the “true” r.
Range restriction is everywhere in business data. Customers who were approved for credit, staff who were hired, products that stayed on the menu, stores that survived: each is a selected group with a narrower range than the population it came from, and correlations inside it are usually weaker than across everyone. The weaker correlation is accurate for the group; it is wrong only if read as a statement about the whole population.
Restriction does not always weaken r. If you select the part of a curve where it is steepest, r can rise: for loads above 7, r = 0.93, more than 0.83 for all days. And restricting to the steep part of a curve shrinks r far less than restricting to a flat part: days between 60 and 74°F still give 0.906 for the iced share, against 0.657 for July. The general rule is that r depends on the range you look at, so always say what range it describes.
Unreliable measurements attenuate r
Every measurement has some error. The door counter misses people in a crowd; a manager timing the queue with a stopwatch on five customers gets a noisy average. Random error adds scatter that has nothing to do with the relationship, so the observed correlation is weaker than the correlation between the true values. Spearman (1904) called this attenuation and gave a correction: if the reliability of each measure is known (the share of its variance that is true variation, often estimated by measuring the same thing twice and correlating the two sets of results), then .
For example, with fictional figures: if the true correlation is 0.80, the load is measured with reliability 0.90 and the stopwatch waits with reliability 0.60, the observed r would be about 0.80 × √(0.90 × 0.60) = 0.59. Dividing an observed r by √(rel_x × rel_y) estimates the true one, but only as well as the reliabilities are known, and it can produce values above 1 when they are underestimated or when sampling error in r is large. Use the correction to judge whether a weak correlation might come from noisy measurement; better still, measure more reliably.
Formulas
Hinge at a threshold
- The hinge: zero below the threshold, the distance above itunits of x
- The original variable (here the peak load)transactions per barista hour
- The threshold, read from the plot or set in advanceunits of x
Assumes. y is roughly flat below c and changes with x above it. A threshold chosen from the same data flatters the fit.
Excel: =MAX(0,A2-7), filled down. Squaring h, =MAX(0,A2-7)^2, allows y to rise ever faster above c.
Correlation over the full range from a restricted one
- Estimated correlation over the full range
- Correlation in the restricted data
- Standard deviation of x over the full rangeunits of x
- Standard deviation of x in the restricted dataunits of x
- How many times wider the full range is
Assumes. A straight-line relationship with even scatter, and selection on x alone.
With k = s ÷ S (below 1) the same formula goes from the full range to a restricted one, and shows that restricting x shrinks r. With a curve or uneven scatter it is only a rough guide.
Attenuation by unreliable measurement
- Correlation between the measured values
- Correlation between the true values
- Reliability of each measure: the share of its variance that is true variation, for example a test–retest correlation
Assumes. Random, independent measurement errors; reliabilities known.
Spearman’s (1904) correction for attenuation. A corrected value above 1 suggests the reliabilities are underestimated (or that sampling error in r is large).
Worked examples
Fictional figures
The Hollyford Hotel changed its rooms’ default thermostat setting each week for eleven weeks, from 17°C to 22°C in steps of 0.5°C, and counted complaints about room temperature per 100 guests: 9.6, 7.1, 5.0, 3.6, 2.4, 2.0, 2.5, 3.4, 4.9, 7.0 and 9.8. The general manager runs CORREL, gets 0.00, and concludes that the setting doesn’t matter. Is she right?
- Plot first: complaints fall from 9.6 to a minimum of 2.0 at 19.5°C and rise again to 9.8 at 22°C, a symmetrical U.
- Explain r: on the cold side (17 to 19.5°C) r = −0.97; on the warm side (19.5 to 22°C) r = 0.96. Over the whole range the two cancel, so r = 0.00, and Spearman’s ρ (−0.03) fails for the same reason.
- Measure against the shape: the distance from 19.5°C has r = 0.97 with complaints, and its square 0.999. The setting explains almost all of the variation in complaints, through its distance from 19.5°C.
Answer. No. r = 0.00 because the relationship is a U, not because there is none: complaints are lowest at 19.5°C and rise steeply on either side.
What it means. The hotel should set rooms near 19.5°C. The manager’s mistake was to read r = 0 as “no relationship” when it means “no straight-line relationship”. Eleven weeks is a small sample and the turning point was read from the data, so the hotel should confirm it over the next season.
Fictional figures
Across the 612 café-days, the peak load (peak transactions per barista hour) and the average peak wait have r = 0.830. Ana wants to know whether to read this as a strong but loose link, and what it means for the roster.
- Band the loads: the mean wait is between about 1.6 and 1.8 minutes in every band up to a load of 7, then 1.73 minutes for 7–8, 2.17 for 8–9, 3.06 for 9–10 and 5.85 for 10 or more. Flat, then steep: a threshold.
- Correlate within ranges: up to a load of 7 (169 café-days) r = −0.10; above 7 (443 café-days) r = 0.93. Below the threshold the load doesn’t go with the wait at all; above it, closely.
- Measure against the shape: with the hinge , r = 0.917; with , r = 0.980. Spearman’s ρ for load and wait is 0.867.
- Read it with care: the threshold of 7 was read from these data, so 0.98 flatters the fit a little. The bands and the within-range correlations do not depend on fitting anything and tell the same story.
Answer. Not loose: waits barely change up to a load of about 7 and rise steeply after it (r = 0.93 above 7; r = 0.980 with the squared hinge). r = 0.830 understates the link because it measures closeness to a straight line.
What it means. For the roster this points to a rule rather than a slope: roster enough barista hours to keep the expected load at or below about 7, because beyond it every extra transaction per barista hour costs more waiting than the last. In this fictional log waits are built to depend on the load, so the rule rests on the case’s planted cause; in real data Ana would test it by rostering differently and watching the waits.
Fictional figures
Millbrook’s manager reviews her weekday rosters. On weekdays the barista hours rostered for the peak and the day’s sales have r = 0.52, and she worries that her rosters barely follow the business. Across all of Millbrook’s days r = 0.88. What explains the difference, and should she change how she rosters?
- Compare the ranges: across all days the peak roster runs from 3.5 to 10 hours (SD 1.78 hours) because weekends are quiet; on weekdays it runs from 6 to 10 hours (SD 0.82). The weekday data cover a much narrower range of x.
- Apply the range-restriction formula as a guide: k = 1.78 ÷ 0.82 ≈ 2.2, and with r = 0.52 on weekdays the formula gives about 0.80 over the full range, close to the 0.88 observed. Most of the gap comes from the narrower range.
- Check what is left: weekday sales vary less too (SD $100 against $167), and day-to-day noise in sales is a bigger share of what is left. A weekday r of 0.52 says that, among similar weekdays, the roster tracks sales only loosely, which is expected when the roster is set in advance from the business the manager expects.
Answer. Mostly range restriction: weekdays use only part of the roster’s range, so r falls from 0.88 to 0.52 even if rostering works the same way on every day.
What it means. The weekday figure is accurate for weekdays and says nothing bad about rostering in general. If the manager wants rosters to follow weekday sales more closely, the question is about forecasting weekday demand, not about the correlation. Whether more staff lead to more sales is a causal question for the correlation-and-causation lesson: here the roster is set to expected business.
Explore
Common mistakes
“r = 0, so the two variables are unrelated.”
r = 0 means no straight-line relationship. A U-shape (complaints against the thermostat setting) or a pattern that rises then falls can have r near 0 and a near-perfect link. Plot the data before concluding anything.
“r = 0.94, so the relationship is a straight line.”
A monotonic curve can give a high r: the iced share is an S, flat at both ends, with r = 0.94. A high r says the points are near some line, not that a line describes them well. Look at the plot or at averages by band.
“r = 0.83 for load and waits: a strong but loose link.”
When the relationship has a threshold, r averages a flat stretch and a steep one. Here waits are unrelated to load below 7 and closely related above it (r = 0.93). Describe the threshold; a single r understates the link.
“Temperature matters less in summer, because r is lower in summer.”
Summer days cover a narrower range of temperatures (SD 6.4°F against 15.0°F), and a narrower range shrinks r even when the relationship is unchanged. Compare slopes or band averages, not correlations from different ranges.
“A weak correlation means a weak relationship.”
Measurement error attenuates r: with reliabilities of 0.9 and 0.6, a true correlation of 0.80 shows up as about 0.59. Before dismissing a link, ask how reliably each variable was measured.
Guided practice
Work through these with hints when you need them. Every hint and every worked solution is there to be used.
Loading four questions…
On your own
No hints this time. Answer, check, and read the feedback; the solution appears once you have answered or if you ask for it. Your first answers count toward mastery.
Loading five questions…
In practice
Fictional case
Ana’s note for the summer stock plan: “Iced share rises with temperature in an S: about 3 points per 5°F on the coldest days, 13 to 16 points per 5°F between 60 and 75°F, and levelling off near 80% above 80°F (2027 log, both cafés). In July the share averages about 75%, so July orders should follow footfall more than temperature. The lower correlation in summer (0.84, against 0.94 for the year) reflects the narrower range of summer temperatures, not a weaker link.”
Her note follows the habits of analysts who deal well with curves. She describes the shape in the units of the decision (percentage points per 5°F) instead of reporting a single coefficient, says over what range each statement holds, and explains a lower correlation before anyone can misread it. The same habits apply wherever relationships bend: price and demand near a competitor’s price, workload and errors near capacity, discounts and orders near a threshold for free delivery.
Thresholds deserve special attention in operations because they are where decisions bite. A service desk, a call centre or a café counter works well until utilisation passes a point, beyond which queues tend to lengthen quickly. A correlation across all days blends the calm days and the overloaded ones; a table of averages by band, or correlations within ranges, shows where the threshold is, and that is what a manager needs in order to plan capacity.
When comparing correlations across teams, sites or periods, check the ranges first. A branch with very similar days will show weaker correlations than one with very varied days, even if the two behave the same way. Report the range each correlation covers, and prefer comparisons of band averages or slopes, which B06 develops.
Knowledge check
Six questions, one attempt each, no hints. Score 80% or more to complete the lesson; you can take it again at any time.
Loading six questions…
Summary
- Pearson’s r measures how closely points cluster around a straight line, not how strongly y depends on x in general.
- A monotonic curve can give a high r (the iced-share S: r = 0.940, ρ = 0.957) while hiding where the relationship is steep and where it is flat; averages by band show the shape.
- A threshold makes r understate a link: peak waits are unrelated to load up to about 7 (r = −0.10) and closely related above it (r = 0.93); a squared hinge at 7 gives r = 0.980 against 0.830.
- A U-shape can give r ≈ 0 with a near-perfect link; measure against the shape (distance from the turning point) and say the turning point was read from the data.
- Logs straighten multiplicative curves (r = 0.950 to 0.994 for the fictional towns); Spearman’s ρ doesn’t change under any monotonic transformation.
- Restricting the range of x usually shrinks r (summer 0.841, July 0.657, against 0.940 for the year; Millbrook’s weekdays 0.52 against 0.88); always say what range a correlation describes.
- Unreliable measurements attenuate r: r_obs ≈ r_true × √(rel_x × rel_y). The correction for attenuation is only as good as the reliabilities.
Key formulas
- Hinge at a threshold
- Correlation over the full range from a restricted one
- Attenuation by unreliable measurement
Terms introduced
- Threshold effect
- A relationship in which y barely changes with x up to a certain value of x and changes markedly beyond it.
- Hinge transformation
- Replacing x with max(0, x − c), which is zero up to a threshold c and rises one for one above it, so that a correlation or a fitted line can follow a relationship that starts at the threshold.
- Range restriction
- Analysing only part of the range a variable can take, such as summer days or hired applicants. It usually shrinks a correlation, though it can raise one when the part selected is where a curve is steepest.
- Attenuation
- The weakening of an observed correlation by random measurement error in either variable; Spearman’s correction divides the observed r by the square root of the product of the two reliabilities.
Sources
- Holmes, A., Illowsky, B. & Dean, S. (2023). Introductory Business Statistics 2e, section 13.1, “The Correlation Coefficient r”. OpenStax. openstax.org/books/introductory-business-statistics-2e/pages…
- NIST/SEMATECH. e-Handbook of Statistical Methods, section 1.3.3.26, “Scatter Plot” (sample plots of quadratic, exponential and other non-linear relationships). itl.nist.gov/div898/handbook/eda/section3/eda33q.htm
- Spearman, C. (1904). “The proof and measurement of association between two things”. American Journal of Psychology, 15, 72–101. Reprinted in International Journal of Epidemiology (2010), 39(5), 1137–1150. doi.org/10.1093/ije/dyq191
