Lu Dong posted on Tuesday, August 22, 2017 - 12:52 pm
Dear Dr. Muthén
I'm trying to run a mediation model for a RCT in Mplus: randomized treatment group --> pre-post changes in mediator --> pre-post changes in outcome
I consider randomized treatment group level 2, and changes in pre-post mediator and outcome level 1. So I think this would be a 2-1-1 model and was trying to implement the 2-1-1 sample script from Preacher et al. example E: http://quantpsy.org/pubs/syntax_appendix_081311.pdf
Here is the syntax I used:
TITLE: 2-1-1 mediation (MSEM)
DATA: FILE IS mydata.csv; ! mydata is in long format
VARIABLE: NAMES ARE ID timepoint Tx mediator outcome; USEVARIABLES ARE ID Tx mediator outcome; BETWEEN IS Tx; CLUSTER IS ID;
ANALYSIS: TYPE IS TWOLEVEL RANDOM;
MODEL: %WITHIN% mediator outcome; outcome ON mediator;
%BETWEEN% Tx mediator outcome; mediator ON Tx(a); outcome ON mediator(b); outcome ON Tx;
MODEL CONSTRAINT: NEW(indb); indb=a*b;
OUTPUT: TECH1 TECH8 CINTERVAL;
--to be continued in the next post---
Lu Dong posted on Tuesday, August 22, 2017 - 12:53 pm
--continued from the above post--
And I have two questions:
1. Is this the correct model for the research question I have? The reason I ask is that in the regular MLM/HLM model I created a Tx by timepoint interaction to capture the pre-post change in the mediator, but this is not present in the Mplus syntax. Should I add this Tx by timepoint to the Mplus model, and if so, could you let me know how to do that or if there is an example available?
2. This model (as written above) did run, but I got this error message. Could you let me know how to interpret this message and what changes should be made accordingly?
THE STANDARD ERRORS OF THE MODEL PARAMETER ESTIMATES MAY NOT BE TRUSTWORTHY FOR SOME PARAMETERS DUE TO A NON-POSITIVE DEFINITE FIRST-ORDER DERIVATIVE PRODUCT MATRIX. THIS MAY BE DUE TO THE STARTING VALUES BUT MAY ALSO BE AN INDICATION OF MODEL NONIDENTIFICATION. THE CONDITION NUMBER IS -0.183D-19. PROBLEM INVOLVING THE FOLLOWING PARAMETER: Parameter 10, %BETWEEN%: TX
I use Mplus to estimate a 1-1-1 twolevel mediation. Both the slope for the a-path (effect from x -> m) and the slope for the b-path (effect from m -> y) vary significantly between groups. The covariance of the a and b slope, however, is not significant. My question is if one should add the covariance to the a*b-product (as recommend in the Handbook of advanced multilevel modeling by Hox) when calculating the indirect effect although, in this case, it is estimated as non-significant?
"When a random slope is estimated, the observed covariate x is used on the within level and the latent variable covariate xbj is used on the between level."
Just to be sure what happens at the within-group level:
The description above means that when a random slope for x is used, there is no decomposition of x into a latent within-part (labelled xwij in the second part of the example in the UG); instead, the observed, uncentred x is used within groups?
I am testing a 2-1-1 mediation x-> m -> y. In our case, I want to separate within and between values of m to compute indirect effects, which occur at the between level given the nature of our model. My problem is that I obtain different results when m is group-mean centered by Mplus than when I introduce a variable containing the group-mean of m (no within variability). The problem is that I obtain different results in this part and I am not sure why. To investigate further, I computed a separate simple analysis mimicking the first part of the model (x-> m).
missing are .; usevariables are M X ; cluster= group; BETWEEN = X; ANALYSIS: TYPE = twolevel random; model: %within%
%between% M ON X;
But if I run the following replacing M with MG (i.e., the group-mean cluster variable of M as aggregated in the data file), I obtain different results which confirms the problem experienced in the 2-1-1 model. Would these results not be the same though? Thanks!
missing are .; usevariables are MG X ; cluster= group; BETWEEN = X MG; ANALYSIS: TYPE = twolevel random; model: %within%
Lüdtke, O., Marsh, H.W., Robitzsch, A., Trautwein, U., Asparouhov, T., & Muthén, B. (2008). The multilevel latent covariate model: A new, more reliable approach to group-level effects in contextual studies. Psychological Methods, 13, 203-229. download paper contact first author show abstract
which shows that the predictor variable X in 2-level regression such as Y on X can be decomposed into a latent within and a latent between part. This is often better than using the group-mean centered X on Within and the group mean of X on Between. So this applies to both the M on X and the Y on M equations in your example. When you don't specify the predictor as either a Within or a Between variable, Mplus does this decomposition by default (this is discussed in the V8 UG on our website, ex9.1, part 2 on pages 274-275).
You may want to get a feel for this by comparing the approach of "observed" decomposition (group-mean centering and group mean) to the approach of latent (automatic) decomposition.