Ths function takes the output of
cond_indirect_effects()
and
computes the difference in
conditional indirect effects between
any two rows, that is, between levels
of the moderator, or two sets of
levels of the moderators when the
path has more than one moderator.
The difference is meaningful when the
difference between the two levels or
sets of levels are meaningful. For
example, if the two levels are the
mean of the moderator and one
standard deviation above mean of the
moderator, then this difference is
the change in indirect effect when
the moderator increases by one
standard deviation.
If the two levels are 0 and 1, then
this difference is the index of
moderated mediation as proposed by
Hayes (2015). (This index can also be
computed directly by
index_of_mome()
, designed
specifically for this purpose.)
The function can also compute the
change in the standardized indirect
effect between two levels of a
moderator or two sets of levels of
the moderators.
This function is intended to be a
general purpose function that allows
users to compute the difference
between any two levels or sets of
levels that are meaningful in a
context.
This function itself does not set the
levels of comparison. The levels to
be compared need to be set when
calling cond_indirect_effects()
.
This function extracts required
information from the output of
cond_indirect_effects()
.
If bootstrap or Monte Carlo
estimates are available
in the input or bootstrap
or Monte Carlo confidence
intervals are requested in calling
cond_indirect_effects()
,
cond_indirect_diff()
will also form
the bootstrap confidence
interval for the difference in
conditional indirect effects
using the stored estimates.
If bootstrap confidence interval is
to be formed and both effects used
the same type of interval, then that
type will be used. Otherwise,
percentile confidence interval will
be formed.