logo

Mediated and Moderated Relationships

GreenBlueBar.gif GreenBlueBar.gif

The question of mediated and moderated relationships has become an important one in psychology in recent years. The issue was popularized by Baron and Kenny (1986) in an article in the Journal of Personality and Social Psychology, and that is the classic reference.

Baron and Kenny distinquished between the situation in which variable B serves a mediating role between variables A and C, and situations in which variable B moderates (or alters) the relationship between A and C. Let's start with an example. If we thought that the relationship between Intelligence and Income was due to the fact that Intelligence is associated with more Education, and that more Education leads to higher Income, then we would label Education as a mediating variable. At the same time, if we assumed that this relationship between Education and Income held for men, but, because of the ills of our society, it did not hold for women, then we would say that the Education --> Income relationship was moderated by Sex.

The example that I will use is built very directly on an excellent study by Kliewer, Lepore, Oskin, & Johnson (1998) on "The role of social and cognitive processes in children's adjustment to community violence." The study was published in The Journal of Consulting and Community Psychology. I have created data which match their data almost exactly, although I have not rounded my variables to integers, and each of the variables was drawn from a normal population before being transformed to have the reported means and standard deviations, as well as the correlational structure of Kliewer et al's study. I have appended the SPSS syntax that created this file to the end of this page.

Theory:

Kliewer et al (1998) studied the relationship between the violence that a child observes or experiences directly and subsequent internalizing problems. They hypothesized that this particular relationship was mediated by the occurrence of intrusive thoughts, such that violence led to intrusive thoughts, which in turn led to internalizing behaviors. Furthermore, they hypothesized that this relationship was itself moderated by the social support and social strains impinging on the child. With considerable support and few strains, the violence that the child witnessed would not lead to a high level of intrusive thoughts, and those intrusive thoughts would not lead to internalizing problems. On the other hand, for those children with little social support and a high level of social strains, the violence -->intrusive thoughts --> internalizing paths would be strong.  Kliewer et al. diagrammed this situation as:

wpe5.jpg (11688 bytes)

   

In this diagram the top line represents a mediating set of relationships, while the vertical arrows represent moderating effects.

Variables:

Kliewer et al. collected data from 40 male and 59 female children aged 8-12 living in moderate- to high-violence areas of Richmond, VA. Data were collected from the children and their caregivers on 10 variables. These variables were

1) Witness violence        2) Victim of violence        3) Intrusive thoughts
4) Internalizing symptoms  5) Social support            6) Social strains
7) Current stress          8) Maternal education        9) Child age
10) Child sex 

The data set contains all of these variables. However for our purposes I will only use some of the variables.

Results:

The descriptive statistics on all variables follows. These statistics are exactly equal to those obtained by the authors.

Mediating Relationships:

Descriptive Statistics

n

minimum

maximum

mean

std. deviation

age

99

7.52

13.67

10.7100

1.2700

gender

99

1.00

2.00

1.5960

.4932

id

99

1.00

99.00

50.0000

28.7228

internal

99

-7.02

4.89

6.2e-17

2.3500

intrus

99

2.25

20.64

10.0900

3.3200

mateduc

99

6.99

17.04

11.7500

1.9100

socsupp

99

15.56

41.91

27.5500

5.2500

sostrain

99

.09

8.56

3.7700

1.7000

stress

99

-2.14

7.29

2.9400

2.1200

violvict

99

-13.01

12.53

5.5404

????

violwit

99

-4.81

52.83

20.3600

12.4800

valid n (listwise)

99 

I can't fit the SPSS printout in, so I'll simply copy the original matrix of correlations.

1 2 3 4 5 6 7 8 9 10
1) ViolWit 1.00 .43 .37 .20 .08 .19 .05 -.18 .20 -.20
2) ViolVict 1.00 .48 .31 -.04 .17 -.02 -.03 .04 -.05
3) Intrus 1.00 .39 -.08 .27 .04 -.25 -.09 .10
4) Internal 1.00 -.17 .33 .27 -.21 -.16 -.04
5) SocSupp 1.00 -.29 -.08 .12 .07 .06
6) SoStrain 1.00 .00 -.19 -.10 .09
7) Stress 1.00 .01 .06 -.08
8) MatEduc 1.00 .04 .01
9) Age 1.00 .00
10) Gender 1.00
Correlations > .20 are significant at p < .05

There is a lot to see in this table, but I'm going to focus on those relationships which relate directly to Kliewer's model. The original authors included additional control variables (demographic variables and stress) in their model, but I will leave them out except for a demonstration after the next topic.

Does Violenct Predict Internalizing Symptoms?

Note that, as hypothesized, the correlation matrix shows a relationship between witnessing violence and later internalizing symptoms. The correlation (r = .20) was significant at p < .05.  Thus we can conclude that there is a linear relationship between the degree to which children witness violence, and their level of internalizing symptoms. Whether or not this is a direct causal relationship is the next question.

Do Intrusive Thoughts Mediate the Violence--> Internalizing Relationship?

Note that witnessing violence is significantly related to intrusive thoughts (r = .37), and that intrusive thoughts are related to Internalizing behaviors (r = .39). These significant relationships are required before we can test a mediating model. If they don't hold, then we can't have mediation. If they do hold, we can then ask if perhaps witnessing violence leads to an increase in intrusive thoughts, which, in turn, leads to an increase in internalizing symptoms.

Suppose that we use both Witnessing violence and Intrusive thoughts as predictors of Internalizing behaviors. If Intrusions mediate the relationship between witnessing violence and internalizing behaviors, then the direct violence --> Internal path should be drastically reduced when intrusions are added to the equation. The results follow, using just ViolWit as a predictor in the first model and ViolWit & Intrus in the second model.

 

Notice that when ViolWit is used alone, it is a significant predictor, with β = .20, t = 2.01, and p = .047. (We already knew this from the intercorrelation matrix.) However when we add Intrus as a predictor, ViolWit is no longer significant, although Intrus is. This is the evidence we seek that intrusive thinking is the mediator in the ViolWit → Intrus relationship. This is a perfect example of Baron and Kenny's description.

We would find a similar relationship if we used the degree to which the child was a victim of violence, in place of just witnessing violence, but I will not show that here.

It is important to note that just because we have the pattern of relationships shown above, does not mean that intrusive thoughts mediate the relationship. We have met the statistical requirement, but that doesn't mean the logical requirement. Suppose, for example, that Intrus was measured a year before the child saw any violence. Then it would have been logically impossible for Intus to work as a mediator, even if the pattern of correlations were exactly the same. To demonstrate mediation you need to be able to make a logical argument about the relationship, as well as to show that it exhibits particular statistical properties. I would assume that for our particular case here, a logical argument can be made as well.

Conclusion:

So far, we have shown that simplying witnessing violence is sufficient to lead children to show internalizing behaviors. We have also shown that this relationship is mediated through intrusive thoughts.

Controlling Other Variables in a Mediating Model:

The preceding discussion is at a very simple level with only two variables. We can extend it to include a situation where we have additional variables that need to be considered, even if they are somewhat tangential to the direct mediating relationship. Suppose that we think that to fully understand the above relationship, we need to also control for demographic variables and concurrent life stress. The child's gender, his or her age, and the level of stress under which he or she generally lives should certainly be related to the level of internalizing behaviors, and we want to take these into account.The only difference in how we test our model is that we will include those variables at the first stage in the model, along with ViolWit.

These results follow:

Notice that we have the same pattern of results. In the first model, violWit is significant, with β = .223, t = 2.258, and p = .026. This is even after we control for the other variables, two of which are sigificant.

When we add Intrus to the model, ViolWit drops to a β = .091, t = .897, p = .372, while Intrus is significant, with β = .328, t = 3.326, and p = .001. Again, Age and Stress are also significant. So, again, we have shown the mediating role of intrusive thoughts.

I have reported beta in each of these analyses, because that is what you normally see as the path coefficient in the model. I won't go into that issue here because of time, other than to show the model as many people would report it.

wpe4.jpg (8466 bytes)

Moderating Relationship

 

Moderating relationships are somewhat more complicated to see, although the calculations are not difficult. If you consider what I have suggested above, which is that the relationship between ViolWit and Intrus will depend upon whether or not the child has strong social support, you will realize that I am talking about what you normally think of as an interaction. Furthermore, you know that an interaction between two variables (A and B) is normally written as A X B, which is really a notation for multiplication. You may also know from elsewhere that we can get the interacting effects of two independent variables just by computing a new variable that is the product of the two separate variables. Thus if A and B were variables in our model, we could add their interaction by predicting Y from A, B, AXB. That is what we will do here, although we will add a little twist.

As suggested, we could create our interaction variable by multiplying our two independent variables together. We could then use that product as a predictor along with the other two variables. The two independent variables would be the equivalent of main effects, and the product would carry information about the interaction. While this would be a legitimate way of testing for an interaction, we would be likely to find that the product of A and B is highly correlated with A or B or with both. This leads to problems with collinearity, and makes the tests on main effects problematic.

An alternative approach is to "center" each of the main effect variables by subtracting their respective means from all observations. We could then form a product of these centered variables, and it would be only weakly correlated to either of them (or with their non-centered counterparts). This approach is often taken, but there is a slightly simpler way that leaves us at the same place. We can simply standardize A and B and then calculate the product of zA and zB. This product will do just as well as the product of centered variables. (I say it is simpler because SPSS will do it automatically through Statistics/Summarize/Descriptives

The following printout has used the main effects of ViolWit and social strain (SoStrain), as well as the product of their standardized values. We could have used the standardized values of ViolWit and SoStrain as our main effects, but the results would have been the same except that the slopes would reflect the different values of the standard deviations of the variables. The t tests on the slopes would have been unaffected, however.

(You might wonder why I switched from social support to social strain. It's really just because I liked the results better, and when you're making up an example, it's nice to have nice results--even if they aren't as nice as I would like.)

These results are almost all that we could ask for. Notice that they illustrate that both ViolWit and SoStrain contribute to the prediction of Intrusive thoughts. Notice also that the interaction term is what some of my colleagues like to call "borderline significant." I don't like that phrase, but I'll accept it here because I want to make a big deal out of this.

I said that it wouldn't make any difference if you standardized ViolWit and SoStrain, although the unstandardized slopes (b) would change. The results of doing that are shown below. Almost everything is the same as in the previous table except for the values of b and the intercept. Those differences just reflect the change in means and standard deviations, and bear a linear relationship to the values in the other table. I calculated these partly to show you what happens, and partly to make my next step easier to calculate.

The borderline significance of the interaction term tells us that social strain moderates the relationship between ViolWit and Intrus. To demonstrate how this works, I'll take a few different values of the standardized values of social strain, and a few different values of the standardized ViolWit, and for each of them I'll look at how the predicted value of Intrus changes with changes in ViolWit and social strain.

 

Standardized Witness Violence

Standardized Social Strain   -2 0 2
-2 3.93 8.75 13.56
0 8.01 10.21 12.41
2 12.10 11.68 11.26

Along the top of the table I have three different representative values for ViolWit. Down the left of the table of I have three different representative values for Social Strain. (Both of these variables are in their standardized form.) The entries in the table are the predicted value of Intrusive thoughts given the model in the previous table. For example, 1.1(-2) + .733(-2) - .654(-2)(-2) + 10.213 = 3.93.

Notice that children who have very high levels of social strain are at high levels of instrusive thoughts no matter how much violence they witness. But children who don't have much social strain only show high levels of instrusive thoughts if they witness a lot of violence. Otherwise, they have low levels of intrustive thoughts. In other words, the effect of ViolWit depends on the level of social strain. This is what we mean by an interaction. It is also what we mean by a moderating effect of social strain.

I must admit that this last paragraph doesn't sound quite like the theory that I developed in the beginning, although that theory was specifically aimed as social support more than social strain. I would be happier if the prediction for low values of SoStrain remained low at all levels of ViolWit, but you can't have everything. I will try to find a way around this before too long. What I have said is accurate, but it doesn't fit neatly together.

You might do well to play with these data. You could replace social strain with social support, and you would see that with high levels of social support, witnessing violence in not that much different from not witnessing it, as far as intrusive thoughts are concerned. But with low levels of social support, witnessing violence has a major effect on intrusive thoughts. You could also investigate the effects of controlling demographic and stress variables.

SPSS Syntax

There is much more that could be made of these data, and I encourage student to play with them.

The following code is for SPSS. You can simply copy it and paste it into an SPSS syntax file.

*  This program generates a set of data which have been drawn from 
*  populations having the pattern of correlations specified in
*  "compute r = { }" below. If you run a principal components analysis 
*  and extract all factors, and enter these factors in the 
*  matrix statements (in place of r1, r2, ...), the output variables
*  will have exactly the pattern of correlations given in r.
*  written by: David C. Howell
*  The factor commands were supplied by Lawrence Gordon.
*  last updated: 4/27/98
new file.
input program.
*  draw 99 cases.
set seed 3458769.
loop i = 1 to 99.
*  draw data for 10 variables. 
do repeat response = r1 to r10.
compute response = rv.normal(0,1).
end repeat.
end case.
end loop.
end file.
end input program.
* modify the next line for your own system.save outfile = "dataout.sav".
* the next commands provide a principal components analysis and
* give orthogonal factors which will then reproduce the matrix exactly.
* you will have to modify in 3 places to adjust to the number of variables 
* that you have in your example.
factor
/variables r1 to r10
/analysis r1 to r10
/print correlation extraction
/criteria factors(10) iterate(25)
/extraction pc
/rotation norotate
	/save reg(all).
	save outfile = "dataout.sav".   

*  SPSS version 8.0 is very fussy about the matrix procedure which follows, and 
*  seems to self-distruct, rather than leave a simple message, if you make the 
*  slightest error. The easiest place for errors is in the correlation matrix. 
*  After you have proofread it, profreed it two more times and then expect to correct 
*  it again when the program fails.  

    matrix.
	get x
	/file = "dataout.sav"
	/variables = fac1_1 to fac10_1.
	
compute r = {1.0, .43, .37, .20, .08, .19, .05, -.18, .20, -.20;
	.43, 1.0, .48, .31, -.04, .17, -.02, -.03, .04, -.05;
	.37, .48, 1.0, .39, -.08, .27, .04, -.25, -.09, -.10;
	.20, .31, .39, 1.0, -.17, .33, .27, -.21, -.16, -.04;
	.08, -.04, -.08, -.17, 1.0, -.29, -.08, .12, .07, .06;
	.19, .17, .27, .33, -.29, 1.0, .00, -.19, -.10, .09;
	.05, -.02, .04, .27, -.08, .00, 1.0, .01, .06, -.08;
	-.18, -.03, -.25, -.21, .12, -.19, .01, 1.0, .04, .01;
	.20, .04, -.09, -.16, .07, -.10, .06, .04, 1.0, .00;
	-.20, -.05, -.10, -.04, .06, .09, -.08, .01, .00, 1.0}.
compute newx = x*chol(r).
save newx /outfile = */variables = nr1 to nr10.
end matrix.
compute violwit = nr1*12.48+20.36.
compute violvict = nr2*2.43*2.28.
compute intrus = nr3*3.32+10.09.
compute internal=nr4*2.35 + 0.
compute socsupp=nr5*5.25+27.55.
compute sostrain=nr6*1.70+3.77.
compute stress=nr7*2.12+2.94.
compute mateduc=nr8*1.91+11.75.
compute age=nr9*1.27+10.71.
recode  (lowest thru -.24=1) (else=2) into gender .
execute .
save outfile = "dataout.sav" 
  /drop nr1 to nr10.
correlations 
	/variables=nr1 to nr10 /print=twotail sig. 
GreenBlueBar.gif GreenBlueBar.gif

David C. Howell
6/26/2015