• Skip to primary navigation
  • Skip to main content
  • Skip to primary sidebar
The Analysis Factor

The Analysis Factor

Statistical Consulting, Resources, and Statistics Workshops for Researchers

  • Home
  • About
    • Our Programs
    • Our Team
    • Our Core Values
    • Our Privacy Policy
    • Employment
    • Guest Instructors
  • Membership
    • Statistically Speaking Membership Program
    • Login
  • Workshops
    • Online Workshops
    • Login
  • Consulting
    • Statistical Consulting Services
    • Login
  • Free Webinars
  • Contact
  • Login

Interpreting Lower Order Coefficients When the Model Contains an Interaction

by Karen Grace-Martin 12 Comments

A Linear Regression Model with an interaction between two predictors (X1 and X2) has the form: 

Y = B0 + B1X1 + B2X2 + B3X1*X2.

It doesn’t really matter if X1 and X2 are categorical or continuous, but let’s assume they are continuous for simplicity.

One important concept is that B1 and B2 are not main effects, the way they would be if there were no interaction term.  Rather, they are conditional effects.

Main Effects and Conditional Effects

A main effect is the overall effect of X1 across all values of X2. That overall effect is the difference in the mean of Y for each one unit change in X1.

If there were no interaction term in the model, then B1 is a main effect, and that is how regression coefficients are generally interpreted.

But B1 is not that when there is an interaction in the model. It is the effect of X1 conditional on X2 = 0.

For all values of X2 other than zero, the effect of X1 is B1 + B3X2.

The biggest practical implication is that when you add an interaction term to a model, B1 and B2 change drastically by definition (even if B3 is not significant) because B1 and B2 are measuring a different effect than they were in a model without the interaction term.

But it isn’t labeled differently on the output. You have to know how to interpret those effects.

So don’t panic if B1 suddenly isn’t significant.  It’s measuring something else altogether.

So B1, in the presence of an interaction, is the effect of X1 only when X2 = 0.

If X2 never equals 0 in the data set, then B1 has no meaning.  None.

Centering to Improve Interpretation

This is a good reason to center X2.  If X2 is centered at its mean, then B1 is the effect of X1 when X2 is at its mean.  Much more interpretable.

Even better is to center X2 at some meaningful value even if it’s not its mean.  For example, if X2 is Age of children, perhaps the sample mean is 6.2 years.  But 5 is the age when most children begin school, so centering Age at 5 might be more meaningful, depending on the topic being studied.

If X2 is categorical, the same approach applies, but with a different implication.  If X2 is dummy coded 0/1, B1 is the effect of X1 only for the reference group.

The effect of X1 for the comparison group is B1 + B3.  To see why, plug in 0 for X2 for the reference group and write out the regression equation.  Then plug in 1 for X2 for the comparison group.  Do the algebra.

Interpreting Linear Regression Coefficients: A Walk Through Output
Learn the approach for understanding coefficients in that regression as we walk through output of a model that includes numerical and categorical predictors and an interaction.

Tagged With: dummy coding, interaction, Interpreting Interactions, interpreting regression coefficients, linear regression, main effect

Related Posts

  • Your Questions Answered from the Interpreting Regression Coefficients Webinar
  • Using Marginal Means to Explain an Interaction to a Non-Statistical Audience
  • Understanding Interactions Between Categorical and Continuous Variables in Linear Regression
  • Interpreting Interactions in Linear Regression: When SPSS and Stata Disagree, Which is Right?

Reader Interactions

Comments

  1. Tongming Kang says

    August 14, 2020 at 10:51 am

    Hi Karan,

    Thanks for this article! It really helped me to gain a better understanding in interpreting interaction in a model.

    And I want to ask you some questions. Let’s say I have a multivariable linear model containing two independent variables. Is it OK to center both two variables before introducing the interaction term? And when it comes to intrepretation, is it always recommended to center predictors? (Or in which condition would it be nice to center predictors?)

    Thanks for your help!

    Reply
  2. sahar says

    July 25, 2020 at 7:10 am

    Hi Karen,
    It was excellent. your explanation was simple, practical and suitable.

    Reply
  3. Bernd says

    July 23, 2020 at 9:28 am

    I made this observation when I compared the outcomes of a mixed-model analysis with two fixed effects, one categorical (A) and one continuous (B), the latter entered the model as covariate. The fixed effect stats for A were quite different in two models with or without the interaction with B in the way you described it. In fact, after using a z-transform of B (in SPSS a z-transform of a variable can be requested via the Descriptives command), the meaning of the main effect of A was established.

    Thanks for the explanation!
    Bernd

    Reply
  4. Alexander Seidel says

    July 23, 2020 at 9:10 am

    For categorial predictors it is indeed important how to center them. Setting them to -1 and 1 (deviation coding) compares the level at 1 to the mean of the predictor, while setting them to -0.5 and 0.5 (simple coding) compares the level at 0.5 to the level -0.5. It also changes the meaning of your parameter estimate (distance from the center of the predictor to distance between levels)

    For more predictor levels this becomes more complicated to code with simple coding, but google helps.

    Reply
  5. Thet says

    May 11, 2019 at 5:57 am

    Hi Karen,

    Thanks a lot for your posts. They are extremely valuable to my thesis.
    I am now having a situation with the confidence intervals of the coefficients in a model with statistical interaction term.

    Using the example in your post, how can I know the confidence interval of each effect?
    1. When X2=0, Y = (B1+B3*0)*X1 = B1*X1
    Can I simply use the confidence interval of B1 generated/calculated by the software output?

    2. When X2=1, Y= (B1+B3*1)*X1
    How can I calculate the confidence interval of that (B1+B3)?

    Or is it nonsense to calculate confidence intervals of each coefficients in such models with interaction?

    With Much Thanks,
    Thet

    Reply
    • Karen Grace-Martin says

      May 31, 2019 at 11:40 am

      Hi Thet,

      It’s more common to report the confidence intervals for each parameter estimate, which is what the software generates. You can’t use the confidence interval of B1 for B1+B3.

      Reply
  6. Elaine says

    March 6, 2016 at 5:01 am

    Omer, it’s not a silly question. Depending on your software, you command it to show the basic info of x. For STATA, its sum X2. I forget for sas but something similar.

    The sum command will show the mean value for X2 in your data. Say it’s 6.2. You must now generate a new variable for X2. In stata, you would say
    gen X2_c (or whatever name you like) = X2-6.2

    Your data is now centered. I believe to center at a different value you would just subtract that value from X2, but that seems too simple. I’m a beginner, too.

    Reply
    • Karen Grace-Martin says

      October 26, 2018 at 4:56 pm

      Hi Elaine,

      No, you got it–it really is that simple. For whatever value you want to center on, just subtract that value from X2.

      Reply
  7. Charles Lao says

    May 29, 2015 at 11:22 am

    Nice post. However, I think the condition only apply if your design matrix is a offset from reference model. For a over-parameterized model or sigma-restricted model B1 will the your main effect.

    Reply
  8. Omer says

    April 27, 2015 at 4:48 am

    Hi Karen,

    This may be a silly question but how do you center X2?

    Reply
    • Soutik says

      August 9, 2017 at 9:06 pm

      Hi Omer,

      You can center X2 by standardizing it, i.e. (X2-mean(X2))/sd(X2)

      Reply

Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

Please note that, due to the large number of comments submitted, any questions on problems related to a personal study/project will not be answered. We suggest joining Statistically Speaking, where you have access to a private forum and more resources 24/7.

Primary Sidebar

This Month’s Statistically Speaking Live Training

  • February Member Training: Choosing the Best Statistical Analysis

Upcoming Workshops

  • Logistic Regression for Binary, Ordinal, and Multinomial Outcomes (May 2021)
  • Introduction to Generalized Linear Mixed Models (May 2021)

Read Our Book



Data Analysis with SPSS
(4th Edition)

by Stephen Sweet and
Karen Grace-Martin

Statistical Resources by Topic

  • Fundamental Statistics
  • Effect Size Statistics, Power, and Sample Size Calculations
  • Analysis of Variance and Covariance
  • Linear Regression
  • Complex Surveys & Sampling
  • Count Regression Models
  • Logistic Regression
  • Missing Data
  • Mixed and Multilevel Models
  • Principal Component Analysis and Factor Analysis
  • Structural Equation Modeling
  • Survival Analysis and Event History Analysis
  • Data Analysis Practice and Skills
  • R
  • SPSS
  • Stata

Copyright © 2008–2021 The Analysis Factor, LLC. All rights reserved.
877-272-8096   Contact Us

The Analysis Factor uses cookies to ensure that we give you the best experience of our website. If you continue we assume that you consent to receive cookies on all websites from The Analysis Factor.
Continue Privacy Policy
Privacy & Cookies Policy

Privacy Overview

This website uses cookies to improve your experience while you navigate through the website. Out of these, the cookies that are categorized as necessary are stored on your browser as they are essential for the working of basic functionalities of the website. We also use third-party cookies that help us analyze and understand how you use this website. These cookies will be stored in your browser only with your consent. You also have the option to opt-out of these cookies. But opting out of some of these cookies may affect your browsing experience.
Necessary
Always Enabled

Necessary cookies are absolutely essential for the website to function properly. This category only includes cookies that ensures basic functionalities and security features of the website. These cookies do not store any personal information.

Non-necessary

Any cookies that may not be particularly necessary for the website to function and is used specifically to collect user personal data via analytics, ads, other embedded contents are termed as non-necessary cookies. It is mandatory to procure user consent prior to running these cookies on your website.

SAVE & ACCEPT