PracticeVideosBlogFlashcards

15.3 Scatterplots, Correlation Coefficient r, Linear Regression & Residuals

Key Takeaways

  • Bivariate numerical associations on scatterplots are evaluated across four distinct dimensions: direction (positive or negative), form (linear or non-linear), strength (weak, moderate, or strong), and unusual features (outliers and influential leverage points).

  • Pearson's correlation coefficient rr is a unitless index bounded by −1≤r≤1-1 \le r \le 1 that measures the direction and strength of linear association only; it is invariant under positive linear transformations of scale and symmetric with respect to xx and yy.

  • The coefficient of determination r2r^2 represents the proportion of total variation in the response variable yy that is explained by the linear relationship with explanatory variable xx in the least-squares model.

  • The least-squares regression line y^=a+bx\hat{y} = a + bx minimizes the sum of squared vertical residuals ∑(y−y^)2\sum (y - \hat{y})^2, with slope b=rsysxb = r\frac{s_y}{s_x}, y-intercept a=yˉ−bxˉa = \bar{y} - b\bar{x}, and guaranteed passage through centroid (xˉ,yˉ)(\bar{x}, \bar{y}).

  • Residuals e=y−y^e = y - \hat{y} must exhibit a patternless, random horizontal scatter around zero in a residual plot to confirm linear model adequacy; systematic curvature reveals non-linearity, and predictions beyond the domain of xx (extrapolation) are fundamentally untrustworthy.

Last updated: September 2026

15.3 Scatterplots, Correlation Coefficient r, Linear Regression & Residuals

Bivariate Quantitative Data and Scatterplot Diagnostics

Bivariate data analysis investigates the relationship between two quantitative variables measured on the same individual entities. In most bivariate settings, researchers distinguish between:

  • The explanatory variable (xx, independent variable), which accounts for, explains, or predicts changes in the response.
  • The response variable (yy, dependent variable), which measures the primary outcome under investigation.

A scatterplot provides the primary graphical display for bivariate numerical data, plotting values of the explanatory variable on the horizontal axis and values of the response variable on the vertical axis. When analyzing a scatterplot on the FTCE Mathematics 6-12 examination, you must systematically evaluate four key attributes:

  1. Direction: An association is positive if larger values of xx correspond to larger values of yy (the scatter drifts upward from left to right). An association is negative if larger values of xx correspond to smaller values of yy (the scatter drifts downward from left to right).
  2. Form: Describes the geometric trajectory of the data points. Form is classified as linear if points cluster along a straight line, or non-linear (curvilinear, exponential, power, or periodic) if the trajectory bends.
  3. Strength: Measures how tightly clustered the observations are around the underlying form. Strong relationships exhibit narrow dispersion around a central curve, whereas weak associations display broad, diffuse scatter.
  4. Unusual Features: Includes isolated outliers (individual points that deviate substantially from the overall bivariate pattern) and clusters/gaps in the data space.

Pearson Correlation Coefficient rr and Coefficient of Determination r2r^2

The Pearson product-moment correlation coefficient rr provides a standardized numerical index measuring the direction and strength of the linear relationship between two quantitative variables. Mathematically, rr is the average product of the standardized scores (zz-scores) of xx and yy:

r=1n−1∑i=1n(xi−xˉsx)(yi−yˉsy)r = \frac{1}{n - 1} \sum_{i=1}^n \left(\frac{x_i - \bar{x}}{s_x}\right) \left(\frac{y_i - \bar{y}}{s_y}\right)

Essential Mathematical Properties of rr

  • Bounded Range: The correlation coefficient is strictly bounded: −1≤r≤1-1 \le r \le 1.
    • r=1r = 1 indicates a perfect positive linear relationship.
    • r=−1r = -1 indicates a perfect negative linear relationship.
    • r=0r = 0 indicates the absence of any linear association.
  • Dimensionless (Unitless): Because rr is calculated using standardized zz-scores, it has no units of measurement. Converting measurements (e.g., changing height from inches to centimeters) leaves rr completely unchanged.
  • Scale Invariance: Adding a constant or multiplying by a positive scalar (x′=c1x+d1,y′=c2y+d2x' = c_1 x + d_1, y' = c_2 y + d_2 with c1,c2>0c_1, c_2 > 0) leaves rr invariant. Multiplying by a negative scalar reverses the sign of rr.
  • Symmetry: Variable roles are mathematically symmetric: r(x,y)=r(y,x)r(x, y) = r(y, x). Swapping which variable is assigned to the xx-axis and yy-axis has zero effect on rr.
  • Linearity Restriction: The coefficient rr measures linear strength only. A bivariate relationship can exhibit a perfect deterministic curved relationship (such as y=x2y = x^2 symmetric over [−3,3][-3, 3]) while yielding r=0r = 0.
  • Non-Resistant Statistic: Like the mean and standard deviation, rr is strongly influenced by extreme outliers.

The Coefficient of Determination r2r^2

The coefficient of determination r2r^2 is the square of Pearson's correlation coefficient. It quantifies the proportion of total variation in the response variable yy that is accounted for by the linear relationship with explanatory variable xx:

r2=SSregressionSStotal=1−SSresidualsSStotalr^2 = \frac{\text{SS}_{\text{regression}}}{\text{SS}_{\text{total}}} = 1 - \frac{\text{SS}_{\text{residuals}}}{\text{SS}_{\text{total}}}
  • Contextual Interpretation: 'Approximately r2×100%r^2 \times 100\% of the variation in the response variable (yy) is explained by the linear relationship with the explanatory variable (xx).'
  • The remaining (1−r2)×100%(1 - r^2) \times 100\% represents residual variation attributable to unmeasured lurking variables or random noise.

The Least-Squares Regression Line (LSRL)

When a scatterplot displays a reasonably linear form, we model the relationship using a straight line. The mathematical model is expressed as:

y^=a+bx\hat{y} = a + bx

where y^\hat{y} (y-hat) represents the predicted value of the response variable for a given value of xx, bb is the slope, and aa is the y-intercept.

The least-squares regression line (LSRL) is the unique straight line that minimizes the sum of the squared vertical deviations (residuals) between the observed data points and the line:

Minimize ∑i=1n(yi−y^i)2\text{Minimize } \sum_{i=1}^n (y_i - \hat{y}_i)^2

Formulating the Regression Equation from Summary Statistics

When given summary statistics (means xˉ,yˉ\bar{x}, \bar{y}, standard deviations sx,sys_x, s_y, and correlation rr), the parameters of the LSRL are calculated directly:

  1. Slope (bb): b=r(sysx)b = r \left(\frac{s_y}{s_x}\right) Because standard deviations are strictly positive, the sign of the slope bb is identical to the sign of the correlation coefficient rr.
  2. Y-Intercept (aa): a=yˉ−bxˉa = \bar{y} - b\bar{x} This algebraic formula guarantees that the regression line always passes through the centroid (point of averages), (xˉ,yˉ)(\bar{x}, \bar{y}).

Contextual Interpretation of Regression Parameters

  • Slope (bb): 'For each 1-unit increase in the explanatory variable xx, the model predicts that the response variable yy will increase (or decrease) by approximately ∣b∣|b| units.'
  • Y-Intercept (aa): 'The predicted value of the response variable yy when the explanatory variable xx equals 0.' The intercept is physically meaningful only if x=0x = 0 is plausible within the context and lies within or near the domain of observed data.

Residual Analysis and Linear Appropriateness

A residual eie_i is the directed vertical distance between an observed data point and the regression line:

Residual =Observed y−Predicted y=yi−y^i\text{Residual } = \text{Observed } y - \text{Predicted } y = y_i - \hat{y}_i
  • A positive residual (ei>0e_i > 0) means the observed point lies above the line; the model underestimated the actual value.
  • A negative residual (ei<0e_i < 0) means the observed point lies below the line; the model overestimated the actual value.
  • A fundamental algebraic property of the LSRL is that the sum and mean of the residuals are always zero: ∑ei=0\sum e_i = 0 and eˉ=0\bar{e} = 0.

A residual plot is a scatterplot displaying explanatory values xix_i (or predicted values y^i\hat{y}_i) on the horizontal axis and residuals eie_i on the vertical axis.

  • Linear Model is Appropriate: The residual plot displays a random, uniform, horizontal band of scatter around the reference line e=0e = 0, with no discernible pattern and approximately constant vertical spread (homoscedasticity).
  • Linear Model is Inappropriate: The residual plot exhibits a clear curved or U-shaped pattern, indicating that the true relationship is non-linear and requiring a polynomial or non-linear transformation.
  • Heteroscedasticity: A fan-shaped or megaphone pattern (where vertical spread expands as xx increases) indicates non-constant variance.

Outliers, High Leverage, Influential Points & Extrapolation

  • Regression Outlier: A data point with an unusually large residual that deviates far vertically from the fitted line.
  • High-Leverage Point: A data point whose explanatory coordinate xx is substantially smaller or larger than the mean xˉ\bar{x}. High-leverage points possess the physical potential to act as a fulcrum, heavily tilting the regression line.
  • Influential Point: An observation that substantially alters the slope, y-intercept, or correlation coefficient when removed from the dataset. High-leverage points that deviate from the linear trend of the remaining data are strongly influential.
  • The Danger of Extrapolation: Extrapolation is the practice of using a regression model to predict values of yy for explanatory values far outside the domain of observed xx-data. Extrapolation is highly unreliable because researchers have no empirical evidence that the linear pattern persists beyond the observed range.

Worked Exemplar: Deriving the LSRL from Summary Statistics

Problem: An educational psychologist investigates the relationship between weekly time spent reading for pleasure in hours (xx) and vocabulary assessment scores on a 100-point scale (yy) among a random sample of 30 middle school students. The sample summary statistics are:

  • Mean reading hours: xˉ=5.0 hours\bar{x} = 5.0\text{ hours}, Standard deviation: sx=2.0 hourss_x = 2.0\text{ hours}
  • Mean vocabulary score: yˉ=70.0 points\bar{y} = 70.0\text{ points}, Standard deviation: sy=8.0 pointss_y = 8.0\text{ points}
  • Pearson correlation coefficient: r=0.75r = 0.75
  1. Compute the Regression Slope (bb):

    b=r(sysx)=0.75(8.02.0)=0.75×4.0=3.0 points per hourb = r \left(\frac{s_y}{s_x}\right) = 0.75 \left(\frac{8.0}{2.0}\right) = 0.75 \times 4.0 = 3.0\text{ points per hour}
  2. Compute the Y-Intercept (aa):

    a=yˉ−bxˉ=70.0−(3.0)(5.0)=70.0−15.0=55.0 pointsa = \bar{y} - b\bar{x} = 70.0 - (3.0)(5.0) = 70.0 - 15.0 = 55.0\text{ points}
  3. State the Regression Equation:

    y^=55.0+3.0x\hat{y} = 55.0 + 3.0x
  4. Evaluate the Coefficient of Determination (r2r^2):

    r2=(0.75)2=0.5625=56.25%r^2 = (0.75)^2 = 0.5625 = 56.25\%

    Interpretation: Exactly 56.25%56.25\% of the variation in vocabulary scores is explained by the linear relationship with weekly reading hours.

  5. Predict Score and Calculate Residual: A student in the sample reads 7.07.0 hours per week and achieves an observed vocabulary score of 79.079.0 points.

    • Predicted score: y^=55.0+3.0(7.0)=55.0+21.0=76.0 points\hat{y} = 55.0 + 3.0(7.0) = 55.0 + 21.0 = 76.0\text{ points}.
    • Residual: e=y−y^=79.0−76.0=+3.0 pointse = y - \hat{y} = 79.0 - 76.0 = +3.0\text{ points}.
    • Interpretation: Because the residual is positive (+3.0+3.0), the observed score lies above the regression line; the model underestimated the student's actual performance by 3.03.0 points.

Regression Parameters and Bivariate Diagnostics Guide

Statistic / ParameterMathematical FormulaContextual MeaningDiagnostic Criterion / Pitfall
Correlation Coefficient rr1n−1∑zxzy\frac{1}{n-1}\sum z_x z_yDirection and strength of linear association (−1≤r≤1-1 \le r \le 1)Only measures linear patterns; highly non-resistant to outliers
Coefficient of Determination r2r^2r2=1−SSresidSStotalr^2 = 1 - \frac{\text{SS}_{\text{resid}}}{\text{SS}_{\text{total}}}Proportion of response variance explained by linear modelDoes not imply causation; unaffected by non-linear relationships
Regression Slope bbr(sysx)r \left(\frac{s_y}{s_x}\right)Rate of change in predicted y^\hat{y} per 1-unit increase in xxAsymmetric: regression of yy on xx differs from xx on yy
Y-Intercept aayˉ−bxˉ\bar{y} - b\bar{x}Predicted value of response variable y^\hat{y} when x=0x = 0Meaningless if x=0x = 0 is outside observed domain or physically impossible
Residual eey−y^y - \hat{y}Vertical error of model prediction for an observed pointSums to zero (∑e=0\sum e = 0); negative residual indicates model overestimation
Residual PlotScatter of (x,e)(x, e) or (y^,e)(\hat{y}, e)Validates linearity and constant error variance (homoscedasticity)Curvature reveals non-linearity; expanding funnel indicates heteroscedasticity
Test Your Knowledge

A statistics educator analyzes the relationship between weekly homework hours (x) and final examination scores out of 100 points (y) for a cohort of students. The summary statistics are: mean x_bar = 10 hours, standard deviation s_x = 4 hours, mean y_bar = 72 points, standard deviation s_y = 12 points, and Pearson correlation coefficient r = 0.60. What is the equation of the least-squares regression line predicting final exam score from weekly homework hours?

A

y_hat = 72 + 0.60x

B

y_hat = 18 + 5.40x

C

y_hat = 54 + 1.80x

D

y_hat = 62 + 1.00x

Test Your Knowledge

A study investigates the relationship between the curb weight of passenger vehicles in thousands of pounds (x) and highway fuel efficiency in miles per gallon (y). The calculated Pearson correlation coefficient between the two variables is r = -0.82. Which of the following is the correct contextual interpretation of the coefficient of determination r^2?

A

Approximately 82% of the data points on the scatterplot fall directly on the least-squares regression line.

B

For each additional 1,000 pounds of curb weight, a vehicle's highway fuel efficiency decreases by 67.24 miles per gallon.

C

There is a 67.24% probability that any randomly selected vehicle will have below-average fuel efficiency.

D

Approximately 67.24% of the total variation in highway fuel efficiency is accounted for by the linear relationship with vehicle curb weight.

Test Your Knowledge

A marine biologist models the weight in grams (y) of a fish species as a function of its fork length in centimeters (x) using the linear regression equation y_hat = -120 + 15x. One captured specimen has a fork length of 24 cm and an actual weighed mass of 215 grams. What is the residual for this observation, and what does it indicate about the model's prediction?

A

The residual is -25 grams; the linear model overestimated the actual mass of the fish.

B

The residual is +25 grams; the linear model underestimated the actual mass of the fish.

C

The residual is -25 grams; the linear model underestimated the actual mass of the fish.

D

The residual is +240 grams; the linear model overestimated the actual mass of the fish.

Test Your Knowledge

An educational researcher fits a least-squares regression line to data relating the number of hours students spend practicing an instrument per week to their performance scores on a musical evaluation. When examining the residual plot (residuals plotted on the vertical axis against weekly practice hours on the horizontal axis), the researcher notices a distinct, parabolic U-shaped pattern where residuals are positive for low practice hours, negative for moderate practice hours, and positive for high practice hours. What does this residual diagnostic pattern demonstrate?

A

The linear model is highly appropriate because the residuals are symmetrically balanced above and below the zero line.

B

The linear model is inappropriate because the systematic curved pattern in the residuals indicates that the true relationship between practice time and performance score is non-linear.

C

The correlation coefficient r must equal 0, proving that practice time has no relationship with musical performance.

D

The data set contains severe high-leverage outliers that must be removed before the linear model can be validated.

Sections you finish are checked off in the contents.