Random intercept model with latent in... PreviousNext
Mplus Discussion > Multilevel Data/Complex Sample >
Message/Author
 Anonymous posted on Tuesday, May 13, 2003 - 5:27 am
Hi. I have a simple 2-level mediation model:
X is a level-2 predictor
M is a level-1 mediator
Y is a level-1 dependent variable

All X, M, and Y are LATENT variables (associated with different observed variables)

The mediation model I have is:

X --> M --> Y (also with direct path from X to Y)

I try to fit an "intercept-as-outcome" model (I wrote the equations as HLM format):

Mediation model part 1 (i.e. M --> Y and X --> Y):
Level-1:
Y_ij = B_0j + B_1j*M_ij + e_ij

Level-2:
B_0j = G_00 + G_01*X_j + U_0j
B_1j = G_10

(note: B_1j is fixed)

Mediation model part 2 (i.e. X --> M)
Level-1:
M_ij = B'_0j + e'_ij

Level-2:
B'_0j = G_00' + G_01'*X_j + U_0j'

My question is: Is it appropriate to run the above model by using the "Complex function" (correction of the SE)? Can you show me how to fit the above model by using the "Twolevel" function? Can you also guide me to any published reference with using the Mplus "Twolevel" function? Thanks in advance.
 bmuthen posted on Tuesday, May 13, 2003 - 3:55 pm
Yes, you can run it as type=complex. The twolevel approach is as follows, apart from defining the factors y, m, x:

Between = x;

Model:

%within%

y on m (1);
m;

%between%
y on m (1);
y on x;
m on x;

The between part of the model describes the variation in the between-level parts of the variables y and m, i.e. their intercepts (means). On %between%, "m on x" lets the x influence act on the between-level part of m. Also on %between%, "y on m" lets the between-level part of m influence the between-level part of y. - This gives the mediation. With the equality statement (1), we get the desired same slope for both the within- and between-part of M,

G_10 * M_ij,

where the total score M_ij is decomposed by Mplus as two uncorrelated components,

M_ij = M_W + M_B,

where M_W is what is used on %within% and W_B is what is used on %between%.

For references to random intercept modeling, see Multilevel section of Mplus' "References", under Training/Research. For random slopes modeling, see Addendum to the User's Guide.
 Anonymous posted on Friday, June 10, 2005 - 11:40 am
Hi!

I tried to fit a simple mediational Multilevel SEM where i02_9 is a level 2 predictor and ka03q3r and threat are level 1 mediators.

My input is as follows:

VARIABLE:
USEVARIABLES ARE tg01q3r tg05q3r
tp01q3r tp05q3r ka03q3r tg02q3r
tg06q3r tp02q3r tp06q3r
sy89q3 i02_9;
BETWEEN IS i02_9;
CLUSTER IS key1;
ANALYSIS: TYPE = TWOLEVEL RANDOM;
MODEL:
%WITHIN%
threatw BY tg01q3r
tg05q3r (1)
tp01q3r (2)
tp05q3r (3)
tg02q3r (4)
tg06q3r (5)
tp02q3r (6)
tp06q3r (7);
sy89q3 ON threatw ka03q3r (8);
threatw;
ka03q3r;
threatw WITH ka03q3r;

%BETWEEN%
threatb BY tg01q3r
tg05q3r (1)
tp01q3r (2)
tp05q3r (3)
tg02q3r (4)
tg06q3r (5)
tp02q3r (6)
tp06q3r (7);
threatb ka03q3r ON i02_9;
sy89q3 ON threatb ka03q3r (8);
sy89q3 ON i02_9;

I get the following error message:

*** WARNING in Model command
In the MODEL command, the following variable is a y-variable on the BETWEEN
level and an x-variable on the WITHIN level. This variable will be treated
as a y-variable on both levels: KA03Q3R
1 WARNING(S) FOUND IN THE INPUT INSTRUCTIONS

What do I have to change in my input-file? I have no ideas...

Many thanks in advance!
 bmuthen posted on Friday, June 10, 2005 - 12:18 pm
It is just a warning. You don't have to worry here, I think.
 Marius Wehner posted on Monday, May 03, 2010 - 3:05 pm
Dear Dr. Muthén,

I try to estimate a two-level analysis with continous dependent variables and missing data across 21 countries. (Mplus Version 5.21)

My input is:

USEVARIABLES ARE country y x1 x2 x3 w;

MISSING ARE ALL (999);
CLUSTER = country;
WITHIN = y;
BETWEEN = w;
ANALYSIS: TYPE = TWOLEVEL;
MODEL: %WITHIN%
y ON x1 x2 x3;
%BETWEEN%
x1 x2 x3 ON w;

I am only interested in the influence of w on x1 x2 x3 on the between level. y is only considered to be influenced on level 1.

I get the same error messages as metioned above:

In the MODEL command, the following variable is a y-variable on the BETWEEN
level and an x-variable on the WITHIN level. This variable will be treated
as a y-variable on both levels: x1
etc.

Did I do something wrong or do I have to change my input-file?
Are missings a problem here?

Many thanks in advance!
 Linda K. Muthen posted on Tuesday, May 04, 2010 - 4:13 pm
If a variable is used as a dependent variable on one level and an independent variable on the other level, it must be brought into the model as a dependent variable on both levels. This is what the warning is telling you. This means that distributional assumptions are made about the variable on both levels. There is nothing you need to do.
Back to top
Add Your Message Here
Post:
Username: Posting Information:
This is a private posting area. Only registered users and moderators may post messages here.
Password:
Options: Enable HTML code in message
Automatically activate URLs in message
Action: