+ - 0:00:00
Notes for current slide
Notes for next slide

Skills Lab 09: Moderation

Different Slopes for Different Folks

Dr Danielle Evans

23 March 2022

1 / 15

Overview

Continuous Moderators & Categorical Moderators

  • Step 1: Centring

  • Step 2: Fit Model

  • Step 3: Interpretation

    • Johnson Neyman Interval

    • Simple Slopes Analysis

    • Interaction Plot

2 / 15

Moderation Recap

  • With moderation we're looking at when variables are related

  • We can investigate whether the effect of our predictor is the same for all people or whether it differs under different conditions depending on the value of another variable – the moderator

  • Differences could be the presence of an effect, the size of the effect, or the direction of the effect



3 / 15

Moderation Recap

  • A moderator is a variable that affects the relationship between two others - it modifies it

  • Can be used in correlational or experimental designs with continuous or categorical variables

    • But don't forget: correlation does not equal causation unless you have a causal design!!
  • We run a moderation in the same way as a linear model but with 3 predictors:


4 / 15

Moderation Recap

  • With our 3 predictors: we have two main effects (i.e., 'lower-order effects'), and one interaction effect (i.e., 'higher-order effects') or in our case the moderation!

  • When using a linear model with multiple predictors normally, each of the effects (bs) are interpreted when the other variables in the model are 0

  • But the interaction term in our moderation analysis means that the bs for the main effects are usually uninterpretable unless we centre our predictors...

5 / 15

Step 1: Grand Mean Centring

  • For continuous variables, we centre them by transforming them into deviations around a fixed point - in grand mean centring this 'fixed point' is the overall mean of that variable

  • We can then interpret our effects at average levels of the other variable rather than at 0

  • To center our predictor and moderator, the code is nice & easy!

data <- data %>%
dplyr::mutate(
predictor_cent = predictor - mean(predictor, na.rm = TRUE),
moderator_cent = moderator - mean(moderator, na.rm = TRUE))




Top Tip! We only need to centre our predictor & moderator - not the outcome!

6 / 15

Step 1: Grand Mean Centring

  • For continuous variables, we centre them by transforming them into deviations around a fixed point - in grand mean centring this 'fixed point' is the overall mean of that variable

  • We can then interpret our effects at average levels of the other variable rather than at 0

  • To center our predictor and moderator, the code is nice & easy!

data <- data %>%
dplyr::mutate(
predictor_cent = predictor - mean(predictor, na.rm = TRUE),
moderator_cent = moderator - mean(moderator, na.rm = TRUE))




Demo! Grand Mean Centring!

7 / 15

Step 2: Fitting our Model

  • Once we've centred our predictor and moderator, we can fit our model!

  • The code for fitting our model should be familiar to us:

my_model <- lm(outcome ~ predictor*moderator, data = data)


  • We can then summarise our model, which should also be familiar to us...
summary(my_model)
broom::tidy(my_model, conf.int = TRUE)
broom::glance(my_model)



8 / 15

Step 2: Fitting our Model

  • Once we've centred our predictor and moderator, we can fit our model!

  • The code for fitting our model should be familiar to us:

my_model <- lm(outcome ~ predictor*moderator, data = data)


  • We can then summarise our model, which should also be familiar to us...
summary(my_model)
broom::tidy(my_model, conf.int = TRUE)
broom::glance(my_model)



Demo! Fitting & summarising our model!

8 / 15

Moderations VS Interactions

  • You might have noticed that the code to do a moderation analysis, is the exact same as interactions from last term! 🤯

  • That's because they're essentially the same thing, except:

    • Interactions are used mainly with two categorical predictors

    • Moderations are used with at least one continuous predictor

  • They also differ conceptually...

  • In moderations we're implying that one of the variables is the driver of the differences in effects - one of our variables is the predictor, and one of them is the moderator

    • With interactions, we don't make that conceptual distinction - they're both seen as predictors
9 / 15

Step 3: Interpretation

  • Now we've fit our model, we want to interpret the results!!

  • The model summary tells us whether we have significant main effects of our predictor and moderator, and also if we have an interaction effect (a moderation)

  • The Johnson-Neyman interval shows us a 'zone of significance'

  • The Simple Slopes analysis compares the relationship between predictor and outcome, at low, average, and high values of the moderator

  • The Interaction Plot visualises the Simple Slopes analysis

10 / 15

Interpretation: Code

For Simple Slopes & Johnson-Neyman interval:

interactions::sim_slopes(model_lm,
pred = predictor,
modx = moderator,
jnplot = TRUE,
confint = TRUE)

For the Interaction Plot:

interactions::interact_plot(model_lm,
pred = predictor,
modx = moderator,
x.label = "Predictor Label",
y.label = "Outcome Label",
legend.main = "Moderator Label")
11 / 15

Interpretation: Code

For Simple Slopes & Johnson-Neyman interval:

interactions::sim_slopes(model_lm,
pred = predictor,
modx = moderator,
jnplot = TRUE,
confint = TRUE)

For the Interaction Plot:

interactions::interact_plot(model_lm,
pred = predictor,
modx = moderator,
x.label = "Predictor Label",
y.label = "Outcome Label",
legend.main = "Moderator Label")

Demo! Interpreting our model!

11 / 15

Categorical Moderators

  • The process and interpretation is essentially the same for categorical moderators

  • The only differences are that:

    • We can't grand mean centre the moderator (but we should with our predictor)

    • & we can't get a Johnson Neyman Interval

12 / 15

Categorical Moderators

  • The process and interpretation is essentially the same for categorical moderators

  • The only differences are that:

    • We can't grand mean centre the moderator (but we should with our predictor)

    • & we can't get a Johnson Neyman Interval








Demo! Fitting, summarising & interpreting our second model!

12 / 15

Different Slopes for Different Folks

  • In our final model, we have two Main Effects but no Moderation effect suggesting that the slopes of attractiveness on dating potential are the same for funny and dull dates...

  • But what if we did have a moderation? What might that look like? Give it a go on the next slide!!

13 / 15

Different Slopes for Different Folks

  • We already have the line for the funny group, let's try drawing a line for the dull group if we did have a moderation!


14 / 15

That's all - happy moderating!



15 / 15

Overview

Continuous Moderators & Categorical Moderators

  • Step 1: Centring

  • Step 2: Fit Model

  • Step 3: Interpretation

    • Johnson Neyman Interval

    • Simple Slopes Analysis

    • Interaction Plot

2 / 15
Paused

Help

Keyboard shortcuts

, , Pg Up, k Go to previous slide
, , Pg Dn, Space, j Go to next slide
Home Go to first slide
End Go to last slide
Number + Return Go to specific slide
b / m / f Toggle blackout / mirrored / fullscreen mode
c Clone slideshow
p Toggle presenter mode
t Restart the presentation timer
?, h Toggle this help
sToggle scribble toolbox
Esc Back to slideshow