Continuous Moderator Variables in Multiple Regression Analysis
A moderator variable is one which alters the relationship between other variables. Suppose
that we are using regression analysis to test the model that continuous variable Y is a linear function
of continuous variable X, but we think that the slope for the regression of Y on X varies across levels
of a moderator variable, M. Put another way, we think that there is a interaction between X and M
with respect to their effect on Y.
If the moderator variable is categorical, we can conduct a “Potthoff analysis” to determine if the
regression of Y on X differs across levels of the categorical moderator -- see my handout “Comparing
Regression Lines From Independent Samples.” Here I shall treat the moderator variable a
continuous variable. The data that we shall use are from the research project which is described at
Misanthropy, Idealism, and Attitudes About Animals. Please do read that document to familiarize
yourself with the research. Do note that the analysis presented in that document treats ethical
idealism as a dichotomous moderator variable. This dichotomy was produced by my classifying
cases with idealism scores greater than the median as being “idealistic” and those with scores less
than or equal to the median as being “nonidealistic.”
The attitude towards animal rights and animal research scale we used consisted of 28 items.
An unrotated factor analysis on these 28 items indicated that there was only one factor on which all
items loaded well. Item-total correlations were good, with Cronbach’s alpha being .91. In other
words, these 28 items were internally consistent, all measuring the same basic construct. A rotated
factor analysis did indicate that two subscale scores could be created, one containing items reflecting
concern with the violation of animal rights by using animals for food, clothing, and fur, and the other
containing items reflecting concern with animal research. Here we shall employ the first subscale,
which I shall refer to as the Animal Rights (AR) scale. After dropping from this subscale three items
with relatively low item-total correlations, we have a 12 item scale with Cronbach’s alpha being .87.
Run the program [Link], which is available at my SAS Programs Page. You will need
to download the data file first. It is [Link], available at my StatData page and in SPSS format
on my SPSS Data Page.
Also useful reading is the section titled “Moderating Relationships” on pages 551-556 in David
Howell’s Statistical Methods for Psychology, 8th ed.
Look at the first page of output. Notice that there are no cases with missing data. If there
were cases with missing data on variables to be used in the regression analysis I would delete them
at this point, prior to standardizing the variables.
In the program note the use of Proc Standard to standardize the variables (in the output data
set “Zs”) to mean 0, standard deviation 1. Also note the creation of the interaction term in the Data
Interaction step. It is not necessary to standardize the variables (or, according to Hayes (2013), to
center any variables), but I find it easier to deal with standardized results.
The simple correlation matrix shows a significant relationship between misanthropy and
support of animal rights, but our moderator variable, idealism, is not significantly related to either
misanthropy or support of animal rights. While ethical idealism may not be related to support of
animal rights here, it may moderate the relationship between misanthropy and support of animal
rights.
Copyright 2019, Karl L. Wuensch - All rights reserved.
[Link]
2
It is commonly recommended that one center all of the variables involved in the interaction
(in this case, misanthropy and idealism) -- that is, subtract from each score on each variable the
mean of all scores on that variable -- to reduce multicollinearity and other problems. We could center
the criterion variable too, if we wanted to interpret scores on it in terms of deviations of the score from
the mean. Centering the criterion variable would affect the intercept but not the other regression
coefficients. We could just standardize our variables to z scores, which are, of course, centered. If
we standardize all of the variables, then our regression coefficients will also be standardized, that is,
Beta weights. That is what I have done here. Rarely is the psychological researcher interested in
unstandardized slopes.
It turns out that the recommendation to center variables to avoid problems with
multicollinearity is BS (Bad Statistics), as explained on pages 282 through 290 of Hayes (2013). The
test of the interaction is absolutely unaffected by such transformations. Centering may, however, be
useful with respect to making some of the regression coefficients have more meaningful
interpretations than they otherwise would have. See Effect of Centering and Standardization in
Moderation Analysis .
Our model is statistically significant, R2 = .113, p < .001, AR = -.02 + .303Misanth +
.067Ideal .146Interact – where all of the variables are standardized. Of most interest, the
interaction term is statistically significant, p = .049, indicating that ethical idealism does function as a
moderator of the relationship between misanthropy and support of animal rights. Yes, we could look
at this interaction from another perspective -- that misanthropy serves as a moderator of the
relationship between idealism and support of animal rights.
Here I find the simple (conditional) slopes for predicting AR from Misanth at each of three
levels of Ideal:
Low Idealism (one standard deviation below the mean):
AR = -.02 + .303Misanth + .067Ideal .146Interact
AR = -.02 + .303*Misanth + .067*(-1) + (-.146)*(-1)*Misanth
AR = .449*Misanth -.069
Medium Idealism (at the mean)
AR = -.02 + .303Misanth + .067Ideal .146Interact
AR = -.02 + .303*Misanth +.067*(0) +(-.146)*(0)*Misanth
AR = .303*Misanth - .02
High Idealism (one standard deviation above the mean)
AR = -.02 + .303Misanth + .067Ideal .146Interact
AR = -.02 + .303Misanth + .067(1) +(-.146)*(1)*Misanth
AR = .157Misanth + .065
Now we shall prepare a plot to illustrate the moderator effect. First we need to obtain some
points. I obtain predicted AR for low (-1), mean (0), and high (1) values of idealism paired with low
(-1) and high (1) values of idealism.
Low Idealism: AR = .449*Misanth -.069
& Low Misanthropy: AR = .449(-1) - .069 = -.518
& High Misanthropy: AR = .449(1) - .069 = .380
Mean Idealism: AR = .303*Misanth - .02
3
& Low Misanthropy: AR = .303(-1) - .02 = -.305
& High Misanthropy: AR = .303(1) - .02 = .301
High Idealism: AR = .157Misanth + .065
& Low Misanthropy: AR = .157(-1) + .065 = -.092
& High Misanthropy: AR = .157(1) + .065 = .222
Here are the conditional regression lines, plotted with Microsoft Graph:
Support for Animal Rights
nonidealist
average
idealist
Misanthropy
Italassi
Italassi is a free program that will allow you to display the interaction on your computer screen
with a plot that shows the relationship between the criterion variable and the predictor variable at
various levels of the moderator variable. In the 2-D display, at any given moment the plot displays a
single conditional regression line, but there is a slider which you can move to change the condition,
the level of the moderator, and as you do so, the regression line changes. I would like you to try this
software. First you need to download it to your personal computer. It is available at Provalis
Research Simply download the file ([Link]) and install it. By default it will install itself in the
Program Files folder in a subfolder named “Provalis Research.” You may want to create a desktop
shortcut icon to the [Link] file in that folder.
Once you have downloaded and installed
Italassi, run it. Click OK on the opening window and
you get a window like this:
Notice that it already has variables labeled,
for an example of a moderator effect. Under the
Equations tab you can find regression coefficients
for predicting the criterion variable from bivariate,
trivariate, and interaction models. Under
Description you can find a description of the
example variables. Click the 2-D View tab and look
4
at the regression line. Click on the slider and move it to see how the regression line changes as you
change the level of the moderator variable.
After playing with the example analysis a bit, click on the variables tab and enter the names of
our centered variables and the lowest and highest values for the predictor (X1) and moderator (X2)
variables, like this:
Next, click on the Equations tab and enter the regression coefficients for our interaction. Just
clear out the coefficients for the reduced models, we don’t have those coefficients (you can get them
and use them if you wish).
Now click the 2D-View and move the slider so that you see how the relationship between
misanthropy and attitude about animal rights changes as idealism moves from low to high.
5
6
Process Hayes
Hayes’ (2013) process analysis code makes it easier to conduct a moderation analysis such
that described above. While the data are still loaded in SAS, open and run the process macro
(Version 2 or Version 3) and then open and run Moderate_Process-[Link]. (code for Version 2 of
Process) or Moderate_Process-[Link] (code for Version 3 of Process).
Version 2: %process (data=Zs,vars=AR Misanth Ideal,y=ar,x=Misanth,m=Ideal,model=1,jn=1,plot=1);
Version 3: %process (data=Zs,y=ar,x=Misanth,w=Ideal,model=1,jn=1,plot=1);
Here are parts of the output not redundant with what has already been shown above.
Moderator values(s) defining Johnson-Neyman
significance region(s)
Value % below % above
0.7788 77.2727 22.7273
Misanthropy is significantly correlated with support for animal rights when the
standardized value of idealism is .77 or lower.
The plot above was produced by the values provided when running Version 2 of Process. The
simple slopes are obtained for one standard deviation below the mean of the moderator, at the mean
of the moderator, and one standard deviation above the mean of the moderator.
With Version 3 of Process the simple slopes are obtained at the 16 th, 50th, and 84th percentiles
of the moderator, leading to this plot:
7
If the moderator were perfectly normally distributed in the sample, one standard deviation
below the mean would be the 15.87th percentile, the 50th percentile would be the mean, and one
standard deviation above the mean would be the 84.13th percentile.
In Hayes’ own words, “the 16th and 84th percentiles of the distribution of W will always be within
the range of the observed data, regardless of the shape of the distribution. And the median (the 50th
percentile) of the distribution of W is always a sensible description of the center. The mean may not
be if W is skewed. Although these might seem like strange percentiles to use (why not nice round
numbers like the 25th 50th and 75th percentiles, for instance?), the 16th, 50th, and 84th percentiles
correspond to a standard deviation below the mean, the mean, and a standard deviation above the
mean if W is exactly normally distributed.”
8
Fair Use of This Document
Reporting the Results from a Simple Moderation Analysis
Nearly Complete Statistical Output – Version 2
RMNET post on this topic
Example of Sequential Analysis With Moderation, SPSS
Return to Wuensch’s Statistics Lessons Page
The url for this document is [Link]
Copyright 2019, Karl L. Wuensch - All rights reserved.