STATISTICAL METHODS · BEGINNER GUIDE
Regression Interaction Term: A Worked Example
Understand an interaction term as a changing slope, with a four-row example and a clear interpretation of both coefficients.
Quick answer: An interaction term lets the association between one predictor and the outcome change depending on another predictor. In a model with x, z and xz, the slope for x is b₁ + b₃z, not just b₁.
What this method answers
The model ŷ = b₀ + b₁x + b₂z + b₃xz includes main effects and a product term. Coefficients for x and z refer to the other interacting variable being zero, so centering can make those reference points easier to explain.
Use an interaction when the research question predicts different relationships across conditions or groups. Plot fitted values over the observed range and report conditional contrasts rather than interpreting the product coefficient alone.
Before running a calculation, write down the population and the exact quantity you want to estimate. A method name alone does not define the question, the comparison or the assumptions.
Steps to follow
- Include both main effects and their product term in the model.
- Set the moderator to each relevant value and calculate the conditional slope.
- Plot predictions only within regions where both groups have data.
- Report the slope difference, uncertainty and limits on causal interpretation.
Keep a record of exclusions, recoding decisions and software settings. That makes the analysis easier to check and repeat.
Worked example
A fictional model predicts study score from practice hours x and a tutoring indicator z (0=no tutor, 1=tutor): ŷ = 50 + 3x + 4z + 2xz.
| Tutor status | Slope per practice hour |
|---|---|
| No tutor (z=0) | 3 + 2×0 = 3 |
| Tutor (z=1) | 3 + 2×1 = 5 |
Without tutoring, the modelled practice slope is 3 points/hour. With tutoring, it is 3 + 2 = 5 points/hour. The interaction coefficient 2 is the difference between those slopes under this model.
Interpret the result carefully
The positive interaction says the fitted practice-score association is steeper in the tutoring group. It does not show that tutoring caused the difference; selection into tutoring could explain it.
Limit to keep in mind: Interpret the interaction only across data-supported values. A product term can be unstable with small samples, poor overlap or uncentered variables whose zero point is meaningless.
When reporting an analysis, include the sample size, estimate, units and uncertainty. Explain why the method fits the sampling and measurement design. Separate planned tests from exploratory checks, and avoid saying that association proves a cause.
Frequently asked questions
Can I include an interaction without both main effects?
Usually the hierarchical model includes the corresponding main effects unless there is a strong design reason otherwise.
What does the product coefficient mean?
In this linear model, it is how much the x slope changes for a one-unit increase in z.
Should I center predictors?
Centering can make main effects refer to meaningful values and may improve numerical interpretation; it does not remove the interaction.
Does a significant interaction prove moderation causally?
No. It describes a modelled difference in association unless the research design supports causal claims.