Cross-level moderator PreviousNext
Mplus Discussion > Multilevel Data/Complex Sample >
Message/Author
 Virpi poyhonen posted on Friday, August 07, 2009 - 4:33 am
I want to test a cross-level interaction where I expect the relation of two individual level variables to be moderated by the association of two other variables. This association would be a group level variable (classroom). For instance, if there is a strong positive association between two variables in certain classrooms is the relation btw individual level variables weakened? I don’t know what would be the best way to do this. Can I use an aggregate of correlation as the classroom level moderator variable or is there a better way to do this?
 Linda K. Muthen posted on Friday, August 07, 2009 - 9:54 am
Cross-level interactions are specified as random slopes in Mplus. See Example 9.2 and slide 43 of the Topic 7 course handout for details.
 Ayesha Delany-Brumsey posted on Tuesday, May 11, 2010 - 2:35 pm
I want to test a cross-level interaction with one level 1 continuous variable and one level 2 continuous variable. I have complex survey data with weight, cluster, stratification, and sub-population. When I try to run the model I receive the following warning and error message:

*** WARNING in ANALYSIS command
The INTEGRATION option is not available with this analysis.
INTEGRATION will be ignored.
*** FATAL ERROR
THIS MODEL CAN BE DONE ONLY WITH MONTECARLO INTEGRATION.

I am having trouble figuring out if there is a way to run this model. Below is my model code. Thank you.:

Model:
%BETWEEN%
bpiint ON c_concdis c_SocCap;
s on c_concdis;
bpiint WITH s;
%WITHIN%
s| bpiint on c_NeighAttch;
bpiint on RSC_sex RSC_Psych;
RSC_sex RSC_Psych c_NeighAttch;
Analysis:
TYPE = COMPLEX TWOLEVEL RANDOM;
ESTIMATOR = MLR;
INTEGRATION = MONTECARLO;
 Ayesha Delany-Brumsey posted on Tuesday, May 11, 2010 - 5:57 pm
I am sorry, I realized I should have been more clear in my original post. I originally tried running the model with simply

Analysis:
TYPE = COMPLEX TWOLEVEL RANDOM;

But I got the same fatal error message.

Thank you,
Ayesha
 Linda K. Muthen posted on Wednesday, May 12, 2010 - 8:26 am
Try adding ALGORITHM=INTEGRATION; to the ANALYSIS command. If that does not help, please send the full output and your license number to support@statmodel.com.
 Ayesha Delany-Brumsey posted on Thursday, July 08, 2010 - 7:53 am
Hello I have a cross-level interaction with one level 1 continuous variable and one level 2 continuous variable. In the output, is the between level intercept of s the main effect of my level 1 variable? If not, where is the coefficient for the main effect for my level 1 variable?

Thank you,
Ayesha
 Linda K. Muthen posted on Friday, July 09, 2010 - 10:13 am
Yes.
 Mukadder  posted on Wednesday, June 01, 2011 - 6:53 am
Hi Dr Muthéns,
I'm trying out a two-level model including upper level mediation (2-2-1 mediation)among three latent variables. I wrote the syntax such that;
USEVARIABLES ARE f1 f2 f3;
WITHIN = f1;
BETWEEN = f2 f3;
CLUSTER IS class;
ANALYSIS:
TYPE = TWOLEVEL RANDOM;
MODEL:
%WITHIN%
f1 ON f2;
f1 ON f3;
%BETWEEN%
f2 ON f3;

Rightfully, the Mplus output gave an error because of the specification of the latents at the levels, specifically f2. Now I'm confused that the output gave me what I intended to do. Because I want to test the effect of f1 on the relationship between f2 and f3.
Your help is appreciated...Thanks
 Linda K. Muthen posted on Wednesday, June 01, 2011 - 10:40 am
I think what you want is the following. You would need to take f1 off of the WITHIN list.

%WITHIN%
f1 BY .....
%BETWEEN%
f1b BY ...
int | f1 XWITH f3;
f2 ON f3 int;
 Mukadder  posted on Wednesday, June 01, 2011 - 12:26 pm
Thank you very much Linda, so happy that this worked!
I have a follow up question...I tried a somehow multilevel path model. I created latent variables such that f1 is the sum of correct responses (German achievement), likely f2 (English achievement) and f3 (French achievement. f1 is a within variable; f2 and f3 are between variables. I followed the syntax you suggested to test the effect of f1 on the relationship between f2 and f3. However, Mplus told me that I can't use the XWITH command with the observed variables. In such a situation would the WITH command be more appropriate?
 Mukadder  posted on Wednesday, June 01, 2011 - 12:29 pm
Sorry I mistyped. The output told me that XWITH is appropriate for only observed variables not latents.

Thanks again.
 Mukadder  posted on Wednesday, June 01, 2011 - 12:44 pm
Linda, I think I have to learn how to read before how to use Mplus!
The output for my trial multilevel path model says:


The XWITH option is not available for observed variable interactions. Use
the DEFINE command to create an interaction variable.
Problem with: INT | f1 XWITH f3
 Linda K. Muthen posted on Wednesday, June 01, 2011 - 3:11 pm
Yes, so use the DEFINE command to create the interaction instead of the XWITH option.
 Ahmad Adeel posted on Thursday, June 30, 2016 - 10:07 am
Hello I am trying a cross level interaction as described in example 9.2. but when in try to run the model, I receive the error, please guide. Thanks.

My code---
usevariables are tn,pp,toi,pij;
within are pp;
between are pij;
cluster is tn;
CENTERING is GRANDMEAN (pp);
analysis: type = twolevel random;
model:
%within%
s | toi on pp;
%between%
toi s on pij;
toi with s;


Error message----
*** ERROR
One or more between-level variables have variation within a cluster for
one or more clusters. Check your data and format statement.

Between Cluster ID with variation in this variable
Variable (only one cluster ID will be listed)

PIJ 16
 Ahmad Adeel posted on Thursday, June 30, 2016 - 11:18 am
in the above problem pij (level 2) is an interaction of pp (level 1) and a moderator (level 2).
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: