Aniko

Regression failure modes: exact fit or best fit?

Lesson progressPractice problems 0/5

Learn when Desmos regression represents exact SAT conditions, when it approximates measured data, and when regression answers the wrong question.

Difficulty
Advanced
Estimated time
55 minutes

What you’ll learn

  1. Tell whether a question gives exact conditions, like function values, or measured or rounded data, and give an exact answer or an estimate to match.
  2. Say what a residual is and what its sign tells you.
  3. Check an exact fit against every original condition.
  4. Use the kind of model the question names or supports.
  5. Spot when regression hides solutions or doesn't have enough information, and switch methods.

Why this matters on the SAT

Know what the fitted model promises

Desmos can fit an equation to almost any table. What matters is the job you're asking that equation to do:

  • If the table gives exact values of a function, the model has to hit every point.
  • If the table holds measured data, a line or curve of best fit only has to follow the trend. It usually misses some points, and that's fine.
  • And for some questions, regression hides the very thing the SAT asks you to report, like a second solution.

So before you read any regression output, ask yourself one thing: hit every point, follow the trend, or skip regression?

SAT example

A researcher records the following measurements. The data are described as having a roughly linear trend.

xx11223344
yy1010151519192626

Which equation is the most appropriate model for the data?

Answer choices

Fast Desmos solution

Type the table into Desmos, then fit both a line and a cubic:

y_1~mx_1+b
y_1~px_1^3+qx_1^2+rx_1+s

The line gives

m=5.2andb=4.5.m=5.2 \qquad\text{and}\qquad b=4.5.

The cubic hits all four points, so it's tempting to call it the better model. It isn't. These are measurements with a roughly linear trend, so the job is to follow the trend, and a line does that. The answer is A.

Words like measured and recorded are good clues, but here the phrases that decide it are roughly linear trend and most appropriate model. Read the whole description before you decide, not one word of it.

Calculator loads as you approach
The cubic hits every point, but the line follows the trend the question describes.

Name the job before fitting

The same regression command can do either job, so the wording of the question has to tell you which one it is. Here’s what to look for.

Exact fit: hit every point

  • The table lists values of a function, like P(0)=50P(0)=50, P(2)=66P(2)=66, and P(4)=50P(4)=50.

  • The question says the graph passes through certain points, like a parabola through (−2,3)(-2,3), (0,5)(0,5), and (2,15)(2,15).

  • Several equations or function values all have to be true at once.

  • The question gives the form, like f(x)=a⋅3x+bf(x)=a\cdot3^x+b, plus one separate fact for each constant, like f(1)=11f(1)=11 and f(2)=29f(2)=29.

Best fit: follow the trend

  • The values were measured, observed, recorded, or rounded, like test scores or daily temperatures.

  • A scatterplot shows points scattered around a roughly linear or curved trend.

  • The question mentions a line or curve of best fit.

  • The question asks you to predict, approximate, or estimate, like the likely score after 66 hours of practice.

Some questions aren't a fitting job at all. Don't start with regression in these four cases:

  • The question asks about all the solutions, like their sum, the greatest or least one, or how many there are.
  • You already know the function and need only one value from it, like f(3)f(3) when you're given f(x)=2x2−1f(x)=2x^2-1.
  • The facts can't pin down every constant, like a single point for the line y=mx+by=mx+b, which has two constants.
  • The question already tells you which model or method to use, like the line of best fit y^=2.5x+6\widehat y=2.5x+6. A new regression would swap in a different one.
Check your understanding:

Is each one an exact fit, a best fit, or the wrong tool? (1) three given values of a quadratic function; (2) measured temperature and battery data with a roughly linear trend; (3) an equation where you need the sum of all real solutions.

An exact fit has to hit every point

Every residual has to be zero

A residual measures how far the model misses one point. It's the actual output minus the output the model predicts:

residual=yobserved−ypredicted.\text{residual} = y_{\text{observed}}-y_{\text{predicted}}.

When the values are exact, the model can't miss at all, so every residual should be 00.

There's one small exception. Desmos does its arithmetic with decimals, so it can leave a leftover as tiny as 2×10−152\times10^{-15}, which is 0.0000000000000020.000000000000002. That's rounding noise, and you can read it as 00. Anything big enough to show up in the first few decimal places deserves a closer look.

Worked example

Suppose a quadratic function has the values

xx−2-20022
f(x)f(x)33551515

Fit a quadratic:

y_1~ax_1^2+bx_1+c

Desmos reports

a=1,b=3,c=5.a=1,\qquad b=3,\qquad c=5.

To see the residuals, define the fitted function and a residual list:

f(x)=ax^2+bx+c
d_1=y_1-f(x_1)

The list comes out as

d1=[0,0,0].d_1=[0,0,0].

Zero residuals tell you the model hits these rows. Since Desmos works in decimals, though, finish by substituting into the original model:

f(−2)=(−2)2+3(−2)+5=3,f(0)=5,f(2)=22+3(2)+5=15.\begin{aligned} f(-2)&=(-2)^2+3(-2)+5=3,\\[1.4em] f(0)&=5,\\[1.4em] f(2)&=2^2+3(2)+5=15. \end{aligned}

All three match, so the exact function is

f(x)=x2+3x+5.f(x)=x^2+3x+5.
Check your understanding:

After a regression on a table of function values, the residuals are [0,0,0.002][0,0,0.002]. Can you call the model an exact fit without checking anything else?

Common mistake:

A residual like 0.0020.002 is fine for measured data, where the model only has to follow the trend. It isn’t fine when the question says the points lie on the model. Then close isn’t enough, and every original condition has to check out when you substitute.

Calculator loads as you approach
The fitted quadratic hits every function value, so every residual is zero.

Best fit allows nonzero residuals

The model follows the overall trend

Now take measured data: hours of practice xx and scores yy. The line of best fit is

y^=3.9x+48.3,\widehat y=3.9x+48.3,

where y^\widehat y, read "y-hat," means the predicted value of yy.

Here's how the predictions compare with the scores that were measured:

xxObserved yyPredicted y^\widehat yResidual y−y^y-\widehat y
11525252.252.2−0.2-0.2
22575756.156.10.90.9
33595960.060.0−1.0-1.0
44646463.963.90.10.1
55686867.867.80.20.2

The residuals aren't all 00, and that's not a mistake. Real measurements scatter. For a linear model, Desmos picks the slope and intercept that make the total squared vertical error as small as possible: square each residual, add them up, and make that total the smallest it can be.

You won't have to work out that total by hand on the SAT.

Desmos can also plot the residuals for you from the regression controls. Here's how to read their signs:

  • A residual above 00 means the point sits above the model.
  • A residual below 00 means the point sits below the model.
  • A residual of 00 means the model passes right through the point.
Try it yourself:

Change the score at x=4x=4 from 6464 to 6262. Before you look, guess: will the line move up or down near that point? Then check the new residuals, and reset the example when you’re done.

Check your understanding:

With the score at x=4x=4 changed from 6464 to 6262, does the line move up or down near that point? What sign does the new residual there have?

Common mistake:

A line of best fit sums up a trend. If you change or throw out measured points only because their residuals aren’t zero, you’re treating a trend as if it were an exact rule.

Calculator loads as you approach
Zoomed in close, the residuals land on both sides of y = 0.

Fit the model family the question supports

A strong statistic doesn't choose the model for you

Next to a fit, Desmos may show a closeness score, written R2R^2 (or r2r^2 for a line). A score of 11 means the model passes through every point. In the opening example, the cubic scores a perfect R2=1R^2=1, and the line scores about 0.9870.987. Go by the score alone and you'd pick the cubic, the wrong answer.

So why does the cubic score so well? It has four constants to adjust, pp, qq, rr, and ss, and that's enough to bend through any four points with different xx-values. On a table that small, a perfect score is easy to get and proves very little.

The kind of equation you fit, like linear, quadratic, or exponential, is called the model family. The family comes from the question: either it names one, or it describes a pattern that points to one, the way "roughly linear" did. The score only tells you how close the points sit to the family you already chose. It can't choose the family for you, and it can't turn rounded data into exact values.

You may also see two other scores. rr is near 11 or −1-1 when the points hug a line, and RMSE is roughly the typical size of a residual. They measure closeness too, so the same rule holds for them.

Check your understanding:

A question describes measured data as roughly linear. A linear regression leaves small nonzero residuals, while a cubic passes through all four points. Which model should you use, and why?

Common mistake:

It’s natural to trust the curve that bends closest to the points. On a small table, though, a curve with more constants can usually bend closer. Pick the model family from the question first, and only then check how well it fits.

Know when regression answers the wrong question

Regression finds one value, not every solution

Worked example

Consider

p2=9.p^2=9.

In a regression, a letter like pp is a parameter: a constant Desmos adjusts until the fit works. So if you type

9~p^2

Desmos looks for one value of pp that fits. It hands back one number, maybe p=3p=3, and the other solution never shows up.

Graph

x^2=9

instead, and you see both solutions:

x=−3andx=3.x=-3 \qquad\text{and}\qquad x=3.

So for any question that depends on every solution, like their sum or the greater one, turn to graphing and solution counting instead.

Regression can't invent a missing condition

One point isn't enough to pin down a line. The line

y=mx+by=mx+b

has two unknown constants, and the point (2,7)(2,7) gives you only one equation:

7=2m+b.7=2m+b.

Lots of pairs work: m=1m=1 and b=5b=5, or m=0m=0 and b=7b=7, or m=3m=3 and b=1b=1. In fact, infinitely many do. No regression result can supply the missing piece. You'd need an independent condition, a genuinely new fact like a second point, not the same fact written another way.

Check your understanding:

The equation (x−2)2=25(x-2)^2=25 has two real solutions, and the question asks for the greater one. Would you use regression or graphing, and what’s the answer?

Common mistake:

Say Desmos reports p=3p=3, and you answer 33 and move on. You’d be only half right, because −3-3 works too. Regression gives each parameter one value. It never promises to list every solution, so when a question is about all of them, graph it or use algebra.

Calculator loads as you approach
Regression gives p one value. The graph shows both solutions.

Verify before you answer

When an answer comes out of a regression, ask yourself five quick questions before you submit it.

  1. What's the job? Decide whether the model has to hit every point, follow the trend, or whether this isn't a regression question at all.
  2. Where did the model come from? It should come from the question, or from a pattern you can point to, not from whichever fit scored highest.
  3. Is there enough information? You need one separate fact for each constant. A line has two constants, so it needs two, like two points. A quadratic has three, so it needs three.
  4. Does the fit hold up? With exact values, substitute into every row. With measured data, look at the trend and the residuals.
  5. Does your answer say the right thing? Call a value exact only when exact conditions back it up. A best-fit prediction is an estimate, so say so. With y^=3.9x+48.3\widehat y=3.9x+48.3, the score after 66 hours is about 7272, not exactly 7272.

A high R2R^2 is nice support, but the question and its original conditions always get the final say.

Example: Choose a rounded exponential model

Worked example

The table shows a set of measurements.

xx00224466
yy400400256256164164105105

The yy-values are rounded to the nearest whole number. An exponential model has the form

y=abx,y=ab^x,

where a>0a>0 and 0<b<10<b<1

.

Which model is most consistent with the data?

  1. A

    y=400(0.64)xy=400(0.64)^x

  2. B

    y=400(0.8)xy=400(0.8)^x

  3. C

    y=256(0.8)xy=256(0.8)^x

  4. D

    y=400(0.8)x/2y=400(0.8)^{x/2}

Step 1

Name the job

The yy-values are rounded measurements, and the question wants the model most consistent with them. That's a best-fit job.

So don't expect the model to reproduce every rounded value exactly.

Step 2

Fit the model the question gives

Type the table, then fit

y_1~a*b^(x_1)

With automatic Log Mode, Desmos reports values close to

a≈399.93andb≈0.8002.a\approx399.93 \qquad\text{and}\qquad b\approx0.8002.

Those point to a=400a=400 and b=0.8b=0.8 in the choices.

One thing about Log Mode: any score Desmos shows here, like R2R^2, is worked out from the logarithms of the yy-values, not from the yy-values in your table. And like any score, it can't overrule the rounded values or the model form the question gives. The real test is the table itself, and that's the next step.

Calculator loads as you approach
The fit lands near a = 400 and b = 0.8, not exactly on them, because the measurements were rounded.

Step 3

Check choice B against the table

Choice B is

y=400(0.8)x.y=400(0.8)^x.

At x=0x=0, 22, 44, and 66, it predicts

400,256,163.84,104.8576.400,\quad256,\quad163.84,\quad104.8576.

Round each one to the nearest whole number and you get

400,256,164,105,400,\quad256,\quad164,\quad105,

which matches the table. The answer is B.

Notice that the unrounded predictions don't equal the table in every row, and they aren't supposed to.

Choice A is the tempting trap. The table's values shrink by a factor of 0.640.64 each time xx goes up by 22, not by 11. At x=2x=2, choice A gives 400(0.64)2=163.84400(0.64)^2=163.84, far from 256256.

Common mistake:

A rounded value like 164164 stands for any value from about 163.5163.5 to 164.5164.5. So choose the model that rounds to the table, instead of demanding that it hit those whole numbers exactly.

Finish the solution

Desmos has already found aa and bb for you. Your part is to check them against both conditions, then work out a+ba+b.

Finish the solution

The function ff is defined by

f(x)=a⋅3x+b,f(x)=a\cdot3^x+b,

where aa and bb are constants. If

f(1)=11andf(2)=29,f(1)=11 \qquad\text{and}\qquad f(2)=29,

what is the value of a+ba+b?

First steps

  1. Treat the two function values as exact conditions.
  2. Put the points (1,11)(1,11) and (2,29)(2,29) in a table.
  3. Fit the given model with y_1~a*3^(x_1)+b.
  4. Desmos reports a=3a=3 and b=2b=2.

Finish it

Calculator loads as you approach
Check both conditions, then add a and b.

Practice problems

Now it's your turn. Before you type anything, name the job: hit every point, follow the trend, or skip regression. Start each one from a clean calculator. When you answer, match your wording to the job, exact or estimate.

Practice problem

A line of best fit predicts a response yy from an input xx:

y^=2.5x+6.\widehat y=2.5x+6.

When x=4x=4, the observed response is 1414. Which statement correctly interprets this observation?

Answer choices
Calculator loads as you approach
Find the prediction, then compare it with what was observed.

Practice problem

The number of items in a simulation is modeled by a quadratic function P(t)P(t). The table gives three exact function values.

tt002244
P(t)P(t)505066665050

Which equation defines P(t)P(t)?

Answer choices
Calculator loads as you approach
Fit or test the quadratic, then check all three rows.

Practice problem

A table records the exact value f(2)=7f(2)=7 for a linear function f(x)=mx+bf(x)=mx+b. A student enters that one row and fits y_1~mx_1+b. Which conclusion is justified?

Answer choices
Calculator loads as you approach
Count the equations and the unknowns before you trust the fit.

Practice problem

What is the sum of all real solutions to

x2−4x−21=0?x^2-4x-21=0?
Calculator loads as you approach
Graph it to see both solutions, then add them.

Finish the lesson

5 practice examples left

Finish the remaining questions correctly to complete this lesson.

Quick recap

  • Name the job before you read the output: hit every point (exact fit), follow the trend (best fit), or use another tool.
  • A residual is observed minus predicted. A positive one means the point is above the model.
  • Exact function values and other stated conditions need every residual to be 00, apart from tiny rounding noise like 2×10−152\times10^{-15}, and every condition to check out when you substitute.
  • Measured, observed, or rounded data can have nonzero residuals, because a best fit follows a trend.
  • Use the model family the question names or supports. A strong fit statistic doesn't choose it for you.
  • Regression can't invent a missing condition or list every solution of an equation.
  • Report exact-fit answers as exact and best-fit predictions as estimates.

Next lesson

Meet every condition

Turn every equation, restriction, and relationship the question gives into one verified model.

Start next lesson

Practice

Practice this lesson

157 SAT questions use what this lesson teaches. Practice a few in a study session at the difficulty you choose.

Start practice

Free practice set

SAT Desmos Regression Practice

Practice Desmos regression on 68 SAT questions, from fitting a table to custom regression, circle regression and equivalent expressions. Every question has a step-by-step Desmos solution.

Practice the set