Multilevel Quadratic Regression PreviousNext
Mplus Discussion > Multilevel Data/Complex Sample >
 Matt M posted on Friday, March 20, 2015 - 11:41 am
I'm in the process of constructing a multilevel model regression model. I've assessed the individual level data in SPSS. A quadratic regression at level one accounts for more variance than linear regression. However the data is clustered (as evidenced by large ICC, and, >2 design effect). Therefore I'd like to test a multilevel quadratic relationship in Mplus.

It seems like a simple issue, but I'm not finding anything online or in the forum regarding defining quadratic relationships in Mplus. Any suggestions?
 Bengt O. Muthen posted on Friday, March 20, 2015 - 11:50 am

xsq = x*x;

and add the xsq variable to the USEV list.
 Kimberly Hall posted on Wednesday, November 16, 2016 - 9:41 am
Hello. We’ve been using the syntax provided in Example 9.16 in the Mplus 7 manual in order to estimate a two level longitudinal model with data clustered within person. We are interested in adding a quadratic term to the script, but were unsure how to do so. Is there a way to do so using the 9.16 syntax? If not, do you recommend using a different Example from the manual? Thank you in advance for your assistance with this.
 Linda K. Muthen posted on Wednesday, November 16, 2016 - 2:04 pm
You can create a time squared variable using the DEFINE command. Then use it in a second random slope statement.
 Kimberly Hall posted on Tuesday, November 22, 2016 - 10:18 am
Hi Linda,

Thank you for your response. When I tried this, I received the following error message:

*** ERROR in VARIABLE command
TYPE=TWOLEVEL requires specification for the CLUSTER option.

Any idea how to correct this? Thank you.
 Bengt O. Muthen posted on Tuesday, November 22, 2016 - 2:42 pm
You have to tell Mplus what the cluster variable is:

Cluster = x;

where x is your cluster variable.
 Kimberly Hall posted on Monday, November 28, 2016 - 5:52 am
Thank you, Bengt. In our script, we'd previously specified IDVARIABLE = person when converting our data file from wide to long. We then specified Cluster = person. This seemed to work fine until we tried to add the quadratic term. Is there a different approach that you suggest for specifying the cluster variable now?
 Linda K. Muthen posted on Monday, November 28, 2016 - 9:40 am
Please send the output and your license number to Changing the model should not affect the cluster variable.
Back to top
Add Your Message Here
Username: Posting Information:
This is a private posting area. Only registered users and moderators may post messages here.
Options: Enable HTML code in message
Automatically activate URLs in message