View/Export Results
Manage Existing Surveys
Create/Copy Multiple Surveys
Collaborate with Team Members
Sign inSign in with Facebook
Sign inSign in with Google

Regression analysis steps: how to run one from start to finish

Ten rows of data, taken through all seven steps, including the part most guides skip: where to click.

The short answer

A regression analysis fits an equation that estimates how much the outcome moves for a one-unit change in each predictor, and how uncertain that estimate is. Seven steps get you from two columns to a sentence you can defend:

  1. State the question as one outcome and a short list of predictors.
  2. Get the data into clean columns, one row per case.
  3. Plot the columns before fitting anything.
  4. Fit the model. Three clicks in Excel, one line in R.
  5. Read the coefficient with its standard error and interval, not only its p-value.
  6. Check the residuals for the things that would make step 5 a lie.
  7. Report the effect in real units, with the interval and the limits.

Every figure on this page comes from one ten-row dataset, printed in full so you can rerun it yourself.

The seven regression analysis steps

The list above again, with the decisions that actually cost people time.

  1. Name one outcome and a short predictor list

    The outcome is the thing you want explained: revenue, a 0-10 rating, minutes on a task. Predictors are the columns you think move it. Write both down before you open the data. A model chosen after looking is a model chosen to flatter you.

    Then a harder constraint: you can only hold constant what somebody actually asked. Across the 109 live templates in our own library, 26 carry a demographic question of any kind and 83 carry none. If the questionnaire never asked for tenure or region, no software will adjust for them afterwards, so choose relevant background variables while the questionnaire is still a draft.

    You can only hold constant what the questionnaire asked

    You can only hold constant what the questionnaire askedDot grid of 109 units, one dot each. You can only hold constant what the questionnaire asked. Asks at least one demographic question 26; Asks none at all 83. They sum to the total of 109. Source: SuperSurvey Question Corpus, 109 live templates and 1,422 questions, read 11 September 2026.Asks at least one demographic questionAsks none at all2683

    Templates in our own published library carrying at least one demographic question. The median template asks 13 questions in total.

    Demographic coverage across 109 live templates Source: SuperSurvey Question Corpus, 109 live templates and 1,422 questions, read 11 September 2026.

    How many rows? Green tested the usual rules of thumb against power calculations and found some support for two of them: at least 50 plus 8 per predictor to test the model as a whole, and 104 plus 1 per predictor to test one predictor on its own.6 For a single predictor that is 58 rows and 105 rows. Settle how many responses you need before you field, while you can still widen the invitation list.

  2. Get the data into clean columns

    One row per case, one column per variable, one header row, numbers stored as numbers. Categories become indicator columns: a four-region field turns into three columns of 0 and 1, with the fourth region as the reference that everything else is compared against.

    Decide what a blank means before you fit. Excel and R both drop an entire row when any column it uses is empty, so your n shrinks silently and two tools can quietly disagree about which rows they used. Print the number of rows the model actually kept and report that one. The rest of the cleaning sequence, from export to a coded table, is how to prepare the response data.

  3. Plot the columns before fitting anything

    A scatter plot takes ten seconds and catches most of what a coefficient cannot tell you: a curve, two clumps with a gap in the middle, one far-out point dragging the whole line. Fit first and you will end up interpreting a slope through a shape that has no single slope.

    Screening with a correlation is the same instinct compressed into one number, and it is worth doing first for the same reason. What r can and cannot support is correlation between survey items.

  4. Fit the model

    In Excel this is Data, then Data Analysis, then Regression. In R it is one call to lm(). Both return the same numbers on the same data, to the last decimal place. The two sections below walk through each one with its output annotated.

  5. Read the estimate together with its uncertainty

    Report the coefficient, its standard error, its confidence interval and its p-value as one object. A slope of 4.41 on its own is a number with no error bars. The same slope with an interval of 3.18 to 5.65 says the data are consistent with anything between $3,178 and $5,648 per extra $1,000 spent, which is a different sentence to write in a board pack. How to interpret the p-value and interval without over-reading either is its own guide.

  6. Check the residuals

    Almost every assumption behind that interval is an assumption about residuals, and residuals do not exist until you have fitted something. So diagnostics come after the model, not before it. That ordering surprises people who expect to qualify their data first.

  7. Report it in units, with the limits

    Like this: "Each additional $1,000 of monthly ad spend was associated with $4,413 more monthly revenue (95% CI $3,178 to $5,648, n = 10)." Real units, the interval, the number of rows, and "associated with" rather than "caused" unless the design supports the stronger verb.

A worked example of regression analysis

A retail chain wants one number. For every extra $1,000 a shop spends on digital ads in a month, how much extra revenue should it expect?

Ten shops, one month. Ad spend and revenue are both in thousands of dollars. Footfall is the count the door sensor recorded, in thousands of visits; it stays out of the model until the two-predictor section.

Ten shops, one month
Store IDAd spend ($000s) Revenue ($000s)Footfall (000s)
A2.0529
B3.5507
C5.06512
D4.05510
E6.57013
F1.5486
G7.07214
H3.05811
I5.56111
J8.07816
What this dataset is

A teaching dataset. It was written to be small enough to retype and to produce a clean, checkable set of outputs. It is not field data from a real chain, and nothing here is a benchmark for what advertising returns.

Take the data with you

Scrolls sideways on a narrow screen: swipe, or focus the block and use the arrow keys.

Store ID,Ad spend,Revenue,Footfall
A,2.0,52,9
B,3.5,50,7
C,5.0,65,12
D,4.0,55,10
E,6.5,70,13
F,1.5,48,6
G,7.0,72,14
H,3.0,58,11
I,5.5,61,11
J,8.0,78,16

The four-column CSV, header row included, is for a spreadsheet or R. The calculator further down reads two numeric columns and nothing else, so the second button copies only ad spend and revenue, ten lines, no header.

Look at it first. The correlation between ad spend and revenue is r = 0.9458: strong, positive and straight enough that a line is a fair summary. If that number had come back near zero, or the scatter had bent, the next step would be a different model rather than this one.

Then fit it. Ordinary least squares picks the intercept and slope that make the sum of the squared vertical distances from the points to the line as small as it can be. On this data that line is Revenue = 40.6014 + 4.4127 x Ad spend.

The fitted model, ten shops
TermEstimate Std. errort p95% interval
Intercept40.60142.698915.043.77e-0734.3776 to 46.8252
Ad spend4.41270.53558.243.53e-053.1778 to 5.6477

Both variables in thousands of dollars, so the ad-spend estimate reads as $4,413 of extra monthly revenue per extra $1,000 of monthly ad spend. R-squared 0.8946, adjusted 0.8814. Residual standard error 3.4871 on 8 degrees of freedom. F(1, 8) = 67.90, p = 3.53e-05. Calculated for this page from the ten-shop teaching dataset printed above. Ordinary least squares, two-sided 95 per cent intervals.

Then read it. Five things, in the order a careful reader wants them:

  • The slope. 4.4127 in thousands of dollars, so about $4,413 of extra monthly revenue per extra $1,000 of monthly ad spend, among these ten shops.
  • The interval. 3.1778 to 5.6477. Ten rows buy a wide interval, and that width is the honest part of the answer. It is the gap between $3,178 and $5,648 of extra revenue per $1,000 spent.
  • A prediction. At $5,000 of monthly spend the line gives 40.6014 + 4.4127 x 5 = 62.6651, so about $62,665 of monthly revenue.
  • The intercept. 40.6014 is revenue where the line crosses zero spend. No shop in the data spends nothing; the lowest spends $1,500. Treat it as where the line sits, not as a forecast for a shop that stops advertising.
  • The range it holds over. Spend runs from $1,500 to $8,000. The equation says nothing about $20,000, and a straight line is exactly the sort of thing that stops being straight out there.

And the caveat that outranks all five: 10 rows is a demonstration, not a decision. Green's thresholds for one predictor were 58 rows and 105 rows. The arithmetic below is exactly right and the business conclusion would still be premature.

How to do a regression analysis in Excel

Two routes. The Data Analysis add-in prints a full report; LINEST gives you numbers that update when the data changes.

Turn the Analysis ToolPak on

It ships with Excel and is switched off by default, which is why most people conclude Excel cannot do regression.7

  • Windows: File, then Options, then Add-ins. In the Manage box choose Excel Add-ins and select Go. Tick Analysis ToolPak. Select OK.
  • Mac: Tools, then Excel Add-ins. Tick Analysis ToolPak. Select OK.

A Data Analysis button appears at the right-hand end of the Data tab. If it is not there, the add-in did not load and nothing below will work.

Run the Regression tool

Put the table above into A1 to D11, header row included, so ad spend is column B and revenue is column C.

  1. Data, then Data Analysis, then Regression, then OK.
  2. Input Y Range: $C$1:$C$11. That is revenue, header included.
  3. Input X Range: $B$1:$B$11. That is ad spend, header included.
  4. Tick Labels, because you included the header row. Leave Confidence Level at 95%.
  5. Under Output options choose New Worksheet Ply. Tick Residuals and Residual Plots.
  6. OK.

Scrolls sideways on a narrow screen: swipe, or focus the block and use the arrow keys.

SUMMARY OUTPUT

Regression Statistics
Multiple R          0.945831
R Square            0.894596
Adjusted R Square   0.881421
Standard Error      3.487068
Observations        10

ANOVA
              df          SS          MS          F  Significance F
Regression     1    825.6229    825.6229    67.8986     3.52751E-05
Residual       8     97.2771     12.1596
Total          9    922.9000

              Coefficients  Standard Error    t Stat      P-value   Lower 95%   Upper 95%
Intercept         40.60142         2.69895   15.0434  3.76801E-07    34.37763    46.82520
Ad spend           4.41274         0.53552    8.2401  3.52751E-05     3.17782     5.64765

Excel's Regression report for the ten shops. Multiple R is never negative: for a one-predictor model with an intercept it is the absolute value of Pearson's r, so a downward-sloping relationship still shows a positive Multiple R and you read the direction from the sign of the coefficient. Here r is 0.9458 and positive, so the two coincide. R Square is r squared, Standard Error is the residual standard error, and Significance F is the p-value for the model as a whole, which with one predictor is identical to the p-value on that predictor. Calculated for this page from the ten-shop teaching dataset printed above. Ordinary least squares, two-sided 95 per cent intervals.

Two things that catch everyone

The X range has to be one contiguous block. If your two predictors sit in columns B and D, Excel will not let you select both. Move them next to each other first. This is the single commonest reason people conclude the tool is broken.

The report is a snapshot, not a formula. Change a number in the source data and nothing in it updates. Run the tool again, or use LINEST instead.

LINEST, when you want it to update

=LINEST(C2:C11,B2:B11,TRUE,TRUE) returns a live five-row block. In Excel 365 it spills on its own; in older versions select five rows by two columns first and confirm with Control, Shift and Enter.

Scrolls sideways on a narrow screen: swipe, or focus the block and use the arrow keys.

    4.412736     40.601415   slope, intercept
    0.535522      2.698947   their standard errors
    0.894596      3.487068   R squared, residual standard error
   67.898627             8   F statistic, degrees of freedom
  825.622877     97.277123   regression SS, residual SS

The annotations on the right are not part of the output; the block is the ten numbers. Calculated for this page from the ten-shop teaching dataset printed above. Ordinary least squares, two-sided 95 per cent intervals.

Two traps in that block. The coefficients come back in reverse order with the intercept last, so with predictors in columns B and C you get the C coefficient, then the B coefficient, then the intercept.8 And LINEST gives you standard errors but no interval, so you build it yourself: =T.INV.2T(0.05,8) returns 2.3060, and 4.4127 plus or minus 2.3060 x 0.5355 gives 3.1778 to 5.6477.

How to do a regression analysis in R

Four lines, no packages. The data goes into a data frame, lm() fits the model, summary() prints it and confint() adds the intervals.

Scrolls sideways on a narrow screen: swipe, or focus the block and use the arrow keys.

stores <- data.frame(
  spend   = c(2.0, 3.5, 5.0, 4.0, 6.5, 1.5, 7.0, 3.0, 5.5, 8.0),
  revenue = c(52, 50, 65, 55, 70, 48, 72, 58, 61, 78)
)

fit <- lm(revenue ~ spend, data = stores)
summary(fit)
confint(fit)

Scrolls sideways on a narrow screen: swipe, or focus the block and use the arrow keys.

Call:
lm(formula = revenue ~ spend, data = stores)

Residuals:
    Min      1Q  Median      3Q     Max
-6.0460 -2.3119  0.7476  2.2754  4.1604

Coefficients:
            Estimate Std. Error t value Pr(>|t|)    
(Intercept)  40.6014     2.6989  15.043 3.77e-07 ***
spend         4.4127     0.5355   8.240 3.53e-05 ***
---
Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1

Residual standard error: 3.487 on 8 degrees of freedom
Multiple R-squared:  0.8946,   Adjusted R-squared:  0.8814
F-statistic: 67.9 on 1 and 8 DF,  p-value: 3.528e-05

R's summary(lm) layout, carrying the values computed for this page. Calculated for this page from the ten-shop teaching dataset printed above. Ordinary least squares, two-sided 95 per cent intervals.

Reading it from the top: the residual five-number summary should look roughly symmetric about zero, and here it runs -6.0460 to 4.1604 around a median of 0.7476. The Estimate column holds the coefficients, Std. Error their precision, t the ratio between the two, and Pr(>|t|) the two-sided p-value. The stars are a legend, not a verdict.

Below the table, the residual standard error of 3.487 is the typical miss in the units of the outcome, roughly $3,487 of monthly revenue. Multiple R-squared is 0.8946 and the F-statistic tests the whole model against an intercept-only one, which with a single predictor is the same test as the t on that predictor. Notice the two p-values match exactly.

Scrolls sideways on a narrow screen: swipe, or focus the block and use the arrow keys.

                 2.5 %     97.5 %
(Intercept)  34.377633  46.825197
spend         3.177820   5.647652

Output of confint(fit). Excel prints these columns without being asked; R makes you ask. Calculated for this page from the ten-shop teaching dataset printed above. Ordinary least squares, two-sided 95 per cent intervals.

For the diagnostics, par(mfrow = c(2, 2)) and then plot(fit) draws the four standard panels: residuals against fitted values, a normal quantile plot of the residuals, a scale-location plot, and the residuals plotted against their leverage values with Cook's distance contours.9 Those four panels are the whole of the assumptions section further down, drawn.

Regression analysis calculator

Paste two columns and it returns Pearson r, Spearman rho, the fitted line, the slope with its 95% interval, and a plot you can switch between the scatter and the residuals. Everything runs in the browser; nothing is uploaded.

It opens on the ten shops from this page, so you can check it against the numbers already printed above before trusting it with yours. Each line is one X,Y pair, numbers only; lines with a missing or non-numeric value are skipped and counted, and the count is shown beside the rows used.

Your data

Load an example
RowXYRemove

Plot

Correlation

Pearson r
Spearman rho
p-value (2-tailed)
Rows used

Regression

R-squared
Slope
Intercept
p-value (slope)

What it says

The p-values come from an incomplete beta function evaluated by continued fraction, the same routine statistical packages use, rather than from a lookup table. On the preset data it agrees with the figures in the tables above to four decimal places. When every point lies exactly on the line, the residual variance is zero and the t statistic has no finite value; the calculator then reports the p-values as their limit, 0, labels the fit as exact, and keeps the slope and intercept, which are still correct.

How regression analysis works: reading the numbers

Every package prints the same handful of quantities under slightly different names. The arithmetic is identical, so once you can read one report you can read all of them. UCLA's Statistical Consulting Group has the long version for SPSS output.1

What each number is for
OutputWhat it isHow to say itHow it goes wrong
CoefficientExpected change in the outcome per one-unit change in that predictor, with the other predictors in the model held fixed"$4,413 more monthly revenue per extra $1,000 of ad spend"Called causal when the data are observational
Standard errorHow much the coefficient would bounce around across repeated samples of the same sizeRarely quoted on its own; it is the raw material for the next two rowsDropped from the report, which throws away both of them
Confidence intervalCoefficient plus or minus the t multiplier times the standard error. Here 2.3060 x 0.5355"3.18 to 5.65"Omitted in favour of a p-value, which answers a narrower question
t statisticCoefficient divided by its standard error"4.4127 over 0.5355 is 8.24"Read as an effect size; it is a ratio, not a magnitude
p-valueHow often a t this far from zero would turn up if the coefficient were really zeroAlongside the interval, never instead of itRead as importance, or as the probability the effect is real
R-squaredShare of the variation in the outcome the model accounts for"The model accounts for 89.5% of the variation"Read as accuracy, or as evidence one model beats another
Adjusted R-squaredR-squared with a penalty for each extra predictorUse it when comparing models with different numbers of predictorsTreated as a stamp of quality rather than a comparison tool
Residual standard errorTypical size of a miss, in the units of the outcome"Predictions land within about 3.5 of the truth"Ignored, though it is the only fit number in real units
F statisticTests the whole model against one with no predictors at allA gate, not a findingUsed to justify keeping weak predictors

Values in the examples are from the single-predictor model above. For a longer treatment of coefficients and their uncertainty, Bzovsky and colleagues is written for clinicians but the reasoning is general.2

The standard error is the row people skip, and skipping it costs both of the two rows below it. The interval and the p-value are the same quantity dressed differently: one says where the coefficient plausibly sits, the other says how surprising it would be if the coefficient were zero. The interval is more useful to a reader who has to decide something, because it is in the units of the decision.

Standardised and unstandardised coefficients

Unstandardised coefficients are in the original units, which is why $4,413 per $1,000 is explainable to anyone. Standardised coefficients express the same relationships in standard deviations, so predictors measured on different scales can be ranked against each other. If you report standardised ones, report the unstandardised ones beside them, because nobody outside the analysis team thinks in standard deviations.

One note on the correlation the calculator prints. Pearson r itself assumes nothing about how the two variables are distributed; it is a formula and it will return a number for any two columns. Bivariate normality is a condition for the usual p-value and interval around r, not for r. Spearman rho replaces the values with their ranks and is the safer choice for ordinal answers or a long-tailed distribution.

Regression analysis with two predictors

"Holding the other predictors constant" is in every regression guide and demonstrated in almost none of them. Here is what it does to a number.

Bigger shops get bigger ad budgets. Footfall in the table above stands in for shop size, and it correlates 0.9017 with ad spend and 0.9749 with revenue. So some part of the $4,413 the first model credits to advertising could simply be the fact that busy shops both spend more and sell more. Add footfall as a second predictor and the fitted equation becomes Revenue = 29.7705 + 1.6657 x Ad spend + 2.1530 x Footfall.

Two predictors, same ten shops
TermEstimate Std. errort p95% interval
Intercept29.77052.725710.921.19e-0523.3253 to 36.2157
Ad spend1.66570.65372.550.03820.1200 to 3.2113
Footfall2.15300.46194.660.00231.0607 to 3.2453

R-squared 0.9743, adjusted 0.9670. Residual standard error 1.8403 on 7 degrees of freedom. F(2, 7) = 132.75, p = 2.72e-06. Calculated for this page from the ten-shop teaching dataset printed above. Ordinary least squares, two-sided 95 per cent intervals.

The ad-spend coefficient falls from 4.4127 to 1.6657 and its interval widens to 0.1200 to 3.2113, which only just clears zero. The claim changes from "every $1,000 goes with about $4,413" to "compare shops with similar footfall and every $1,000 goes with about $1,666, and the data cannot rule out a great deal less".

One extra column cuts the advertising effect by more than half

One extra column cuts the advertising effect by more than halfDot plot of 2 values on a shared 0 to 6 scale. One extra column cuts the advertising effect by more than half. Ad spend alone 4.4; Footfall held constant 1.7. Ranges: Ad spend alone 3.2 to 5.6; Footfall held constant 0.1 to 3.2. Source: Calculated for this page from the ten-shop teaching dataset printed above. Ordinary least squares, two-sided 95 per cent intervals.Ad spend alone4.4Footfall held constant1.7p = 3.53e-05p = 0.0380.01.02.03.04.05.06.0

Estimated extra monthly revenue, in thousands of dollars, per extra $1,000 of monthly ad spend. The bar is the 95 per cent confidence interval, the dot is the estimate.

The ad-spend coefficient before and after footfall enters the model Source: Calculated for this page from the ten-shop teaching dataset printed above. Ordinary least squares, two-sided 95 per cent intervals.

That is what holding a variable constant means in arithmetic. 1.6657 is the ad-spend slope among shops that have the same footfall, rather than across all shops regardless of size. Nothing was removed from the data; a second column was added, and the first column was asked to explain only what the second could not.

R-squared rises from 0.8946 to 0.9743. That on its own is no evidence at all, because R-squared cannot fall when you add a column, even a column of random numbers. Adjusted R-squared, which charges you for each predictor, also rises, from 0.8814 to 0.9670, and that is the weaker but real signal.

What the second column cost

Degrees of freedom fell from 8 to 7, because ten rows now support three estimated quantities instead of two. And the two predictors overlap badly: they correlate 0.9017 with each other, giving a variance inflation factor of 5.35. The widened interval is that overlap showing up in the arithmetic, not a flaw in the method.

How to check the regression analysis assumptions

A model is not a fact, and none of these have to hold perfectly. What you are looking for is whether the model is badly enough misspecified that the interval you are about to publish is meaningless. Four of the five need a fitted model before you can look at them at all, which is why diagnostics come after the fit and not before it. Introductory treatments in Schroeder and colleagues3 and Gordon4 cover each in detail.

  • Linearity. Plot the outcome against each predictor. If the cloud bends, a straight line will misstate the effect at both ends. Transform the predictor, add a squared term, or use a model that does not assume a line.
  • Independent errors. Several responses from one person, one team or one shop are not independent observations. Standard errors come out too small, so intervals come out too narrow and everything looks more certain than it is. Cluster-robust standard errors or a multilevel model handle it.
  • Constant spread of the residuals. The residual cloud should not fan out as the fitted value grows. If it does, the coefficient is still unbiased but its standard error is wrong; heteroskedasticity-robust standard errors fix the standard error without touching the estimate.
  • Roughly normal residuals. This one is about the inference, not the fit. The coefficients themselves need no distributional assumption at all; the t-based p-value and the interval do, and at 10 rows there is no large-sample argument to fall back on. At several hundred rows the central limit theorem does most of the work and mild skew stops mattering. Read it off the normal quantile plot.
  • Influential rows. One extreme case can carry a whole coefficient. Look at the leverage values and Cook's distance, then investigate the row rather than deleting it. A shop that opened mid-month is a data-collection fact worth knowing, not an outlier to quietly drop.

Multicollinearity is not an assumption

It gets filed under assumptions on most pages, including the previous version of this one, and it does not belong there. Ordinary least squares assumes nothing about how your predictors relate to each other. It fails outright only when one predictor is an exact combination of the others, at which point there is no unique answer to compute.

What overlap does is make each coefficient hard to pin down, because the data contain very little information about one predictor once the others are held fixed. Measure it with the variance inflation factor: regress predictor j on all the others, take its R-squared, and VIF equals 1 divided by (1 minus that R-squared). An Introduction to Statistical Learning gives the working threshold as a VIF above 5 or 10.5 In the two-predictor model above the VIF is 5.35, right on the lower line, which is exactly why the ad-spend interval got so wide.

The fix is rarely statistical. Either accept that the two predictors cannot be separated by this data and say so, combine them into one index, or collect data where they vary independently.

Which regression analysis to use

The shape of the outcome decides the family. Everything above is ordinary least squares, which is the right starting point when the outcome is a number that can sit anywhere on a scale.

Outcome shapes and model families
OutcomeSurvey exampleModelWhat the coefficient means
A numberAverage of several rating items; revenue; minutesLinear regression, ordinary least squaresChange in the outcome per one unit of the predictor
Yes or noChurned; would recommend; completed the formLogistic regressionChange in the log-odds, usually reported as an odds ratio
Ordered categoriesOne five-point agreement item on its ownOrdinal logistic, or numeric with careShift towards the higher categories
A countSupport contacts last month; number of visitsPoisson or negative binomialMultiplicative change in the expected count

The third row is the common case in survey work and the one most often waved through. 45.3% of the 1,422 questions in our own published template library are rating items, and 98.9% of those use five points. So the commonest survey outcome is an ordered category, not a continuous number. Treating a single five-point item as numeric assumes the gap from 1 to 2 equals the gap from 4 to 5, which nobody has checked. Averaging several items into one index makes that assumption far easier to live with, which is the main practical argument for multi-item agreement scales over single questions.

SuperSurvey Question Corpus, 109 live templates and 1,422 questions, read 11 September 2026.

Common mistakes in a regression analysis

Most bad regressions are not arithmetic failures. They are reporting failures, and these four account for the majority of them.

  • Reading a coefficient as a cause. A coefficient is an association inside your model, on your data. Adding controls narrows the gap between association and cause but never closes it, because the control you did not measure is the one that matters.
  • Fitting many predictors and reporting the survivors. The median template in our library asks 13 questions. Throw the other 12 at one outcome and keep whatever clears 0.05. If nothing at all were related you would still have about a 46% chance of at least one apparent winner, from 1 minus 0.95 to the 12th. Name the model before you fit it and label the rest as exploration.
  • Treating R-squared as a score. It measures how tightly the points sit around the line, not whether the model is right, useful or causal. The two-predictor model above reaches 0.9743 on ten rows, which should worry you rather than please you.
  • Predicting outside the observed range. The line is fitted where the data are. Outside that span it is an assumption wearing an equation, and the further out you go the more of the answer is assumption.

One more that sits underneath all four. A regression describes the cases that are in the data. Whether it describes anybody else is a question about how those cases were selected, which is what sampling is rather than anything the model can tell you. Everything upstream of the fit, the wording, the scale and who answered, decides what the coefficient is allowed to mean, and the survey learning centre covers those decisions.

Questions people ask

What is simple linear regression?

One predictor, one outcome, one straight line: outcome = intercept + slope x predictor. "Simple" counts the predictors, not the difficulty. Add a second predictor and it becomes multiple regression, which changes what every coefficient means without changing any of the mechanics.

Is an Excel trendline the same as running a regression?

The line and the equation are identical, and if you tick "Display R-squared value" you get that too. What a trendline never gives you is a standard error, an interval or a p-value, so it cannot answer whether the slope is distinguishable from zero. It is a picture of the fit, not an analysis of it. Use it to look, then run the Regression tool to report.

How many rows do I need to run a regression?

Arithmetically, one more than the number of things you are estimating, which is why ten rows happily produced a full report above. Usefully, far more. Green's two rules of thumb ask for 50 plus 8 per predictor before you trust the model as a whole, and 104 plus one per predictor before you trust an individual coefficient. He is careful about their limits: both assume a medium-sized relationship, and the first overshoots once you get past about seven predictors. Below the floor the estimate is not wrong, it is just imprecise, and the interval will say so if you print it.

Should I check the assumptions before or after fitting?

After, mostly. People expect to qualify their data first, but four of the five need a model to exist before there is anything to look at, because they are about what is left over once the line is drawn. Only linearity can be inspected up front, from the scatter plot. So the honest order is fit, look at the diagnostics, then decide whether the first fit is the one you report.

What is the difference between correlation and regression?

Correlation is symmetric and unitless: swap the two columns and r is unchanged, and r tells you nothing about how many dollars or points anything moves. Regression is directional and keeps the units, so it answers "how much" rather than "how tightly". A useful test of which you need: if the answer you owe somebody has a unit attached to it, you need a regression.

Can I compare R-squared between two different models?

Only if both models predict the same outcome on the same rows. Even then, the model with more predictors wins automatically, so compare adjusted R-squared instead, or hold out some rows and compare how well each model does on the rows it never saw. Comparing R-squared across different outcomes, or across different datasets, is not a comparison of anything.

How we counted

The ten-shop dataset is a teaching dataset, written for this page and printed in full so that every figure on the page can be checked rather than taken on trust. It is not field data and it is not a benchmark. The ad-spend and revenue columns are unchanged from the March 2026 version of this page; footfall was added for the two-predictor section.

Every number was computed twice, by two implementations written independently of each other: one in JavaScript using an incomplete beta function evaluated by continued fraction, one in Python using exact rational arithmetic for the fit and Simpson integration of the t density for the tail probabilities. They agree to at least nine significant figures. The fitted values are exact rationals: the slope is 1871/424 and the intercept is 17215/424.

The Excel and R blocks reproduce each tool's own output layout with the values from that computation. Run the code and you should see these numbers; the column spacing your console chooses may differ.

The library figures come from the SuperSurvey template library: 109 live templates and 1,422 questions, read on 10 September 2026. A question counts as demographic if it asks about the respondent rather than the subject of the survey: age, gender, tenure, role, region, income. The limit that matters: this is our own published library. It shows what one survey vendor publishes as good practice, not what the world's surveys do.

References

  1. Chen, X., Ender, P., Mitchell, M. and Wells, C. (2003). Regression with SPSS. UCLA Statistical Consulting Group (OARC). stats.oarc.ucla.edu
  2. Bzovsky, S., Phillips, M. R., Guymer, R. H., Wykoff, C. C., Thabane, L., Bhandari, M. and Chaudhary, V. (2022). The clinician's guide to interpreting a regression analysis. Eye, 36(9), 1715-1717. nature.com
  3. Schroeder, L. D., Sjoquist, D. L. and Stephan, P. E. (2016). Understanding Regression Analysis: An Introductory Guide (2nd ed.). SAGE. sagepub.com
  4. Gordon, R. A. (2015). Regression Analysis for the Social Sciences (2nd ed.). Routledge. routledge.com
  5. James, G., Witten, D., Hastie, T. and Tibshirani, R. (2013). An Introduction to Statistical Learning, section 3.3.3, page 101. Springer. "As a rule of thumb, a VIF value that exceeds 5 or 10 indicates a problematic amount of collinearity." Free PDF at statlearning.com
  6. Green, S. B. (1991). How many subjects does it take to do a regression analysis. Multivariate Behavioral Research, 26(3), 499-510. doi.org/10.1207/s15327906mbr2603_7
  7. Microsoft. Use the Analysis ToolPak to perform complex data analysis. support.microsoft.com
  8. Microsoft. LINEST function. support.microsoft.com
  9. R Core Team. lm: Fitting Linear Models. R stats package documentation. stat.ethz.ch
  10. SuperSurvey Question Corpus, 109 live templates and 1,422 questions, read 11 September 2026.

Michael Hodge: Survey methodologist and editor, SuperSurvey. Bachelor of Science (Psychology), University of Wollongong, with coursework in psychometrics and research methods. Designing surveys since 2003. About the author and how these guides are reviewed

What to read next

A regression needs two clean columns and enough rows. Both of those are decided while you are writing the questionnaire, not afterwards.

Collect data for your analysis

Free to send, no card. Or start from a ready-made survey template and change the wording.