How to work with a moderating variable in the regression test with SPSS?

Studies that aim to determine the relationship between two variables, the regression equation is typically applied. However, sometimes the strength or the direction of this relationship could be controlled by other variables. This influencing or control variables are said to be a moderating variable and the effect of these interactions is represented as an interaction effect.

For example, in a causal relationship between salary and health-related expenses, age has an interaction effect. Young people spend comparatively less on their health as compared to older people. Age is thus the moderating variable in the determination of the amount of money spent on health from their salary.

Presence of a moderating variable in SPSS
Presence of a moderating variable in SPSS

Process of examining the moderating effect presence in regression

As the moderating variable is considered as an independent variable, thus multiple regression analysis is performed for examining the impact of moderating variable and its interaction effect. Following steps are followed to assess the presence of moderating variable in a linkage between variables.

Step 1: Import the data into SPSS

Step 2: Compute the standardized value of independent variables by clicking on Analyze > Descriptive Statistics > Descriptive as shown below.

Computing the standardised value of independent variables in SPSS
Figure 2: Computing the standardised value of independent variables in SPSS

Select all the independent variables including the moderation variable for computation of standardized values. Click on ‘Save standardized values as variables’ and then select ‘ok’.

Computation of standardized values  in SPSS
Figure 3: Computation of standardized values in SPSS

Computed standardized values will appear in the datasheet of SPSS as shown below.

Standardized values
Figure 4: Standardized values

Step 3: Determine the interaction effect by clicking on Transform > Compute variables

Transformation of data
Figure 5: Transformation of data

The new variable needs to be created to store the value of the interaction effect. Name the variable by entering its name in ‘Target Variable’.

Naming the variable
Figure 6: Naming the variable

Multiply the standardized value of moderator with the standardized value of the independent variable individually and select click on ‘OK’.

Interaction effect computation
Figure 7: Interaction effect computation

A new variable will be created in SPSS Datasheet consisting of interaction effect as shown below.

Result of interaction effect computation
Figure 8: Result of interaction effect computation

Note: Repeat the step 3 until interaction effect for each independent variable is computed i.e. in case of three independent variables i.e. A, B, and C and one moderator i.e. M. Step 3 will be repeated thrice i.e. for computing ZA*ZM, ZB*ZM, and ZC*ZM.

Step 4: Regress the dependent variable on the independent variable, moderator, and interaction effect in two blocks wherein 1 block consist of the only independent variable and 2nd block include interaction effect along with independent variable and moderator.

Block 1 specification
Figure 9: Block 1 specification
Block 2 specification
Figure 10: Block 2 specification

Does age work as a moderating variable factor between salary and health expenses?

In order to validate whether age act as an interacting variable in linking the salary and health expenses, the regression analysis is necessary. Below stated hypothesis is tested to verify this linkage:

H0: There is no moderating effect of age on the linkage between salary and health expenses.

HA: There is a moderating effect of age on the linkage between salary and health expenses.

Results are shown in the below table.

Health Expense Coefficient T-statistic p-value R2 Adjusted R2 F Ratio
Model without moderation effect
Constant .422 1.314 .195 .731 .719 63.756
Salary .361 2.190 .034      
Age .540 2.965 .005      
Moderation Effect
Constant .558 1.143 .259 .731 .714 41.772
Salary .370 2.201 .033      
Age .502 2.401 .020      
Interaction -.033 -.374 .710      

Table 1: Regression Results

Above table shows that with the inclusion of the interaction effect of age in the relationship between salary and health expenses, the value of R2 is same i.e. 0.731 but the Adjusted R2 has decreased i.e. from 0.719 to 0.714. Adjusted R2 value shows that about 71.4% of the variation in health expenses is represented by salary wherein age work as a moderator. Furthermore, though still more accurate prediction about health expenses could be done (F-ratio > 1) with the inclusion of interaction effect, this accuracy has decreased i.e. F-ratio decreased from 63.756 to 41.772. Finally, Model 2 has the p-value of 0.710 for interaction effect which shows that the null hypothesis of having no moderating effect of age on the linkage between salary and health expenses is not rejected because the value is greater than the significance level of the study i.e. 0.05. However, the p-value of age shown in model 1 is less than the significance level of the study i.e. 0.005 < 0.05. Thus, age works as an independent variable in influencing the health expenses of a person instead of a moderator.

Riya Jain

Research analyst at Project Guru
Riya is a master in Economics from Amity University. She has a keen interest in econometrics and data analysis. She was a part of the Innovation Project of Daulat Ram College, Delhi University. Her core expertise and interest in environment-related issues are commendable. Apart from academics, she loves music and travelling new places.
Riya Jain

Discuss