AP Precalculus · Competing Function Model Validation

Bivariate Statistics and Residual Plots

A regression curve can look convincing while missing the same way at several inputs. Use scatterplots and residuals to spot those misses, compare three models on the same data, and explain which fit you would use.

Maths practice notebook and a scientific calculator

Read the scatterplot before fitting a curve

Bivariate data record two measurements for each observation. Plot each pair (xi,yi) as a point, with the explanatory variable x horizontally and the response y vertically. Label both axes with variables and units. For instance, place hours studied on the horizontal axis and test score in points on the vertical axis.

Describe the pattern

Look for a positive or negative direction, a straight or curved form, and how tightly points follow that form. Describe clusters and gaps if they stand out. Use the actual variables in your description.

Check unusual observations

A point far from the pattern is an outlier. An observation with an extreme x-value has high leverage, so it can pull a regression line. Check whether the fit changes substantially when that point is left out. A far-right point that follows the trend can have high leverage and little influence.

Consider why the variables move together. A positive association between outdoor temperature and ice cream sales can be useful for prediction. Association alone cannot establish a causal effect. Other variables, such as season or foot traffic, may matter.

CandidateWhat to look for over equal input stepsContext check
LinearRoughly constant first differences.Adding similar amounts each step makes sense.
QuadraticRoughly constant nonzero second differences.A change in slope or a single turning point makes sense on the modeled interval.
ExponentialRoughly constant ratios between successive positive outputs.Multiplying by a common factor each step makes sense.

With unequal input steps, use slopes ΔyΔx to compare rates. For a positive exponential pattern, use (y2y1)1x2−x1 to estimate the factor per unit. Use the shape and context to propose a model, then test the fit with residuals.

Calculate a residual and interpret its sign

Use the observed response and the model's prediction at the same input. The hat in y^ marks a predicted value. A residual has the same units as the response.

ei=yi−y^i
ResidualPoint compared with fitModel behavior
ei>0Above the fitted curveUnderestimates the actual value
ei<0Below the fitted curveOverestimates the actual value
ei=0On the fitted curvePredicts the observed value exactly

Worked example · A prediction falls short

Suppose a learner studies 12 hours and scores 30 points. The line y^=8+1.7x predicts 8+1.7(12)=28.4 points.

e=30−28.4=1.6

The line underestimates the score by 1.6 points. The absolute error |e| is also 1.6 points. When the residual is negative, the absolute error still gives a nonnegative size.

In a residual plot, keep the original x-value and put ei on the vertical axis. The horizontal line at e=0 means no error. A scatter of small residuals around zero without a clear pattern supports the model on the observed interval. A curve indicates systematic errors. Widening spread can show that predictions are less precise for some inputs. Count and size alone cannot explain the pattern.

Use the sign in context. A planner estimating how many visitors a venue can hold may prefer to overestimate demand when running out of space is costly. An overestimate has a negative residual.

Compare linear, quadratic and exponential fits

A website records visits each day after a new page goes live. In this example, x is days since launch and y is the visits on that day. Start by looking at the paired data. Then hold the data fixed and change the model.

Day since launchObserved visits
039
155
269
391
4124
5158
6214
7279
8370

Compare fits on the same nine observations

The first graph shows the data and fitted model. The second shows its residuals. Day four is circled in both. Check each residual axis scale when comparing error sizes.

The line overestimates through most of the middle days and underestimates near both ends.

An upward straight line cuts through the rising data. It is below the first two and last two points, and above the middle observations.The residuals form a U-shaped pattern. They are positive on days zero, one, seven and eight, and negative from day two through day six.

y^≈39.21667x−1.42222

Day 4 recorded 124 visits. The model predicts about 155.44 visits, giving a residual of about −31.44 visits.

The line's residuals are positive near the ends and negative in the middle. It also predicts a negative visit count on day zero. The quadratic accounts for curvature, but runs of positive and negative residuals remain. The exponential has much smaller residuals on both sides of zero with no clear systematic curve in this sample. A nearly constant proportional increase is also plausible over these first few days.

Write an AP-style model justification

“I would use an exponential model for days 0 through 8. Its residuals are close to zero without a clear pattern. The linear residuals are positive at both ends and negative across much of the middle, so the line most often overestimates there.”

Then state an assumption. Here the visitor growth rate is assumed to stay roughly proportional over that short interval. If a campaign ends or demand levels off, the same fit may stop being useful. A fit to the observed data does not establish a long-term trend.

Interpolate cautiously. A prediction inside the observed range is an interpolation. A prediction beyond day 8 is an extrapolation, where there is no observed value to check the model against. Keep the model's applicable interval and the response units in your answer.

Use graphing technology. Enter the paired x- and y-values into a table. Run linear, quadratic and exponential regressions with the same data. Store or copy each model, evaluate it at each observed input, and graph the residuals against the original inputs. Calculate from the stored coefficients and round the reported result at the end.

Understand the least-squares regression line

The least-squares line y^=a+bx, also written y^=b0+b1x, minimizes the sum of squared vertical residuals ∑ei2 among lines. Squaring keeps positive and negative residuals from canceling. The fitted line with an intercept goes through (x¯,y¯).

Slope

Use the ratio of cross-deviations to squared input deviations, or use correlation and the sample standard deviations when both variables vary.

b=∑(xi−x¯)(yi−y¯)∑(xi−x¯)2
b=rsysx

Intercept

Subtract the predicted change from the mean response. The intercept is the model prediction at x=0 and has the same units as y.

a=y¯−bx¯

Worked example · Find the line from summary statistics

Use x¯=10, y¯=25, r=0.85, sx=4, and sy=8. Here x is hours studied and y is test score in points.

b=0.85·84=1.7
a=25−1.7(10)=8
y^=8+1.7x

For each additional hour of study, the predicted score increases by 1.7 points. The predicted score at zero hours is 8 points. Interpret that baseline only if zero is meaningful and reasonably supported by the data. At the mean input 10, the line predicts the mean response 25.

For AP Precalculus, practise constructing a model with technology and interpreting its parameters in context. The formulas here explain how the line is calculated and are useful for checking the output.

What correlation and r2 add to a scatterplot

Pearson's correlation coefficient r measures the direction and strength of a linear association. It is unitless and lies between −1 and 1. It is undefined when either variable has zero spread.

r=∑(xi−x¯)(yi−y¯)∑(xi−x¯)2∑(yi−y¯)2

Read the sign and strength

r=1 is a perfect positive line and r=−1 is a perfect negative line. Values like 0.5 and −0.5 indicate the same strength in opposite directions. At r=0, there is no linear association as measured by r. For example, y=x2 at the five inputs −2,−1,0,1,2 has r=0 despite following a perfect parabola.

Rough descriptions of strength

One classroom convention calls values of |r| above 0.8 strong, between 0.5 and 0.8 moderate, between 0.3 and 0.5 weak, and below 0.3 very weak. The labels and boundaries depend on the context. Describe the scatterplot when the exact label is unclear.

Read the coefficient of determination

For simple least-squares linear regression with an intercept and a varying response, squaring r gives the proportion of the observed variability in y accounted for by the line with x.

r2=1−∑(yi−y^i)2∑(yi−y¯)2

It describes variability in the data. A value of 0.90 does not mean that 90% of predictions were correct.

r2Interpretation for the fitted line
0.90The line accounts for 90% of the observed response variability.
0.64The line accounts for 64% of the observed response variability.
0.25The line accounts for 25% of the observed response variability. Look at the residuals before drawing a conclusion about its usefulness.

A large value can hide a pattern. The visits data give r≈0.956 and r2≈0.914 for the line. Its residuals still form a clear curve. Use the residual plot to justify a fit. Compare model errors on the same response scale, especially after a logarithmic transformation.

Fit an exponential and read a semi-log plot

A positive exponential model has an initial value a>0 and a multiplier b>0 per unit of x. It grows when b>1 and decays when 0<b<1.

y^=abx=aekx,k=lnb

Worked example · Interpret a growth factor

For the population model y=100(1.05)x, the initial population is 100 and the factor 1.05 means 5% growth each year. After 10 years the model gives 100(1.05)10≈162.89, or about 163 individuals.

If you know two positive outputs, divide the later output by the earlier one and take the root corresponding to the number of input units between them. Then use either known pair to solve for a.

Worked example · Recover a model from a semi-log line

For positive y, a semi-log plot keeps x on a linear scale and uses logarithmic spacing on the y-axis. One way to read that pattern is to plot Y=logny on ordinary axes for a base n>1.

Y=(lognb)x+logna

A roughly straight pattern supports exponential behavior. If the transformed line is Y=2+0.1x using base 10, undo the logarithm to get a=102=100 and b=100.1≈1.259.

y=100(100.1)x

The original response increases by about 25.9% per input unit. A straight line on the log scale describes multiplicative change on the original scale. Check predictions and residuals in original units before interpreting how many visits, points or people the model misses by.

With a known baseline c in the model y=c+abx, you can linearize logn(y−c) when y−c>0. When no baseline is supplied, an approximately straight trend on a semi-log plot can suggest exponential behavior. Check the residuals and context to decide whether a plain or shifted exponential fits.

Read more examples in the exponential functions guide and logarithmic functions guide.

Build a complete AP model answer

  1. Choose the family. Use a rate, second difference, ratio or feature of the scatterplot. Compare outputs across equal input intervals when using differences or ratios.
  2. Write the prediction. Give the equation or the value with its units. State what the variables represent and use full calculator precision until rounding.
  3. Support the conclusion. Refer to the table or describe the residual pattern. Explain overestimation or underestimation using the observed and predicted values at the same input.
  4. Limit the model. State where the fit is supported and name a relevant assumption, such as a growth factor continuing over the measured period.

Topic 1.13 connects model choice to assumptions, and Topic 1.14 covers constructing and using models. Topics 2.5 and 2.6 apply these skills to exponential data and competing fits. Topic 2.15 connects exponential models to semi-log plots. The formulas for r and r2 are supporting statistics for this lesson. On AP function-model questions, explain the evidence requested in the prompt.

Practice with worked answers

Write your answer and one piece of evidence before opening the solution.

1. A model predicts 46 visits and the actual value is 41. Find the residual and interpret it.

The residual is 41−46=−5 visits. The model overestimates by 5 visits.

2. A residual is 3 points and the prediction is 26 points. What was observed?

Add the residual to the prediction. The observed value is 26+3=29 points.

3. Consecutive outputs are 18,24,30,36 every one input unit. Which model fits this pattern?

The first differences are all 6. Use a linear model with slope 6 output units per input unit.

4. Consecutive outputs are 5,8,13,20,29 at equal input steps. Which model fits?

First differences are 3,5,7,9. The second differences all equal 2, so a quadratic fits this pattern.

5. Outputs are 64,48,36,27 at successive unit inputs. Give the model type and multiplier.

The ratios 4864, 3648, and 2736 equal 34. This is exponential decay with multiplier 0.75 per step, corresponding to a 25% decrease.

6. A linear fit gives r2=0.96, with positive residuals at both ends and negative residuals in the middle. Is the line appropriate?

The residuals show a systematic curve, so the line misses in different directions across the range. Compare a curved model and check its residuals even though the linear r2 is high.

7. For the fitted line y^=8+1.7x, predict the score at 15 hours. If the observed score is 31, find the error.

The predicted score is 8+1.7(15)=33.5 points. The residual is 31−33.5=−2.5 points, so the absolute error is 2.5 points.

8. If r=−0.8 for a simple least-squares line with an intercept, interpret r2.

(−0.8)2=0.64. The line accounts for 64% of the observed response variability. The negative sign of r describes the direction.

9. A base-10 transformed line is log10y=1+0.2x. Find the original multiplier.

Raise 10 to both sides. Then y=10(100.2)x, so the multiplier is 100.2≈1.585.

10. A model is fitted with observations from day 0 to day 8. Classify predictions for day 6.5 and day 20.

Day 6.5 is inside the range, so it is interpolation if a fractional day makes sense in the situation. Day 20 is extrapolation because it is outside the observed range.

Official AP Precalculus questions and resources

Start with the sample residual-plot question. Then practise using table values to name a model and giving a contextual reason for where a prediction overestimates.

Need help with bivariate statistics?

A NUM8ERS tutor can practise model choice, calculator regressions and residual interpretation with you.

Book a free consultation

Prepared by NUM8ERS using the AP Precalculus framework effective Fall 2026.