Variation within cluster PreviousNext
Mplus Discussion > Multilevel Data/Complex Sample >
 Erik Thoonen posted on Tuesday, October 21, 2008 - 1:03 pm
Today, I tried to perform multilevel path-analyses using a SPSS-datafile saved as a .dat-file.
Running the Mplus-imput file resulted in the next error: "One or more between-level variables have variation within a cluster for one or more clusters". However, inspecting the data-file made clear there are now differences within clusters.

What may explain this Mplus-error?

Thanks a lot,

 Linda K. Muthen posted on Tuesday, October 21, 2008 - 2:25 pm
Your data could be being read incorrectly for a variety of reasons -- blanks in the data set, commas in the data set instead of periods for decimals etc. Please send your input, data, output, and license number to if you can't figure this out.
 Aurelie Lange posted on Wednesday, October 01, 2014 - 7:01 am
Dear Dr. Muthen,

I got the same error-message, but I actually have real variations within clusters.
I have a complex twolevel model with two clusters:
- therapist
- cohort (all families treated by the same therapist in the same year)

When I look up the error message, I see clients treated within the same cohort (thus by the same therapist in the same year), but the different families were treated in different teams, as the therapist changed team in that year.

Can I include or specificy this variation in the model? Or would I need to exclude all variation from my data before running the analyses?

Thank you for your advice.

 Linda K. Muthen posted on Wednesday, October 01, 2014 - 6:06 pm
I can't understand your design.
 Aurelie Lange posted on Monday, October 06, 2014 - 4:47 am
I am sorry for the lack of clarity. In my study, families are nested within cohorts, which are nested within therapists, which are nested within teams.
A cohort consists of all the families seen by the same therapist in the same year.

We are replicating a previous study, which used a complex twolevel multilevel model. The COMPLEX command was used to adjust standard errors for nonindependence within therapists, and the TWOLEVEL command was used to account for nonindependence within cohorts. This way, lower levels (families, cohorts) of substantive interest were explicitly included in the multilevel model, whereas the level-3 nesting unit (therapists) was considered a nuisance and used only to adjust the standard errors. Finally, we modeled the level 4 nesting unit (team) as a level-2 fixed effect. Thus, therapist and cohort were defined as clusters, whereas team was a between-level variable.

If a therapists changes from one team to the other (which happens for a few therapists), the data is cross-classified. In the original study, this was solved by creating additional cohorts for therapists who were cross-classified.

The most recent Mplus version can accomodate for cross-classified data. However, according to the manual TYPE=CROSSCLASSIFIED can't be combined with COMPLEX.

message continued in next post.
 Aurelie Lange posted on Monday, October 06, 2014 - 4:47 am
second part of message:

Would it be possible to use the CROSSCLASSIFIED command in my current design?
Also, would this command be appropriate if cross-classification is only present in a few cases?

I hope this post makes more sense. I am looking forward to your reply.

Thank you so much for your time.

Kind regards,

P.s. sorry for having to use 2 posts
 Linda K. Muthen posted on Monday, October 06, 2014 - 8:40 am
The is no COMPLEX CROSSCLASSIFIED. I would create additional cohorts as done in the original study.

In the future, please limit posts to one window.
 Aurelie Lange posted on Tuesday, October 14, 2014 - 11:59 am
Dear Dr. Muthen,

I created additional cohorts, as was done in the oringinal study and now believe that there is no longer any variation on any of the between-level variables within the clusters. Yet, I still receive the same error message. Would you have any further suggestions of where or what to look for in my data or model specifications, to find what problem is underlying this message?

Thank you for your time.

Kind regards,
 Bengt O. Muthen posted on Tuesday, October 14, 2014 - 5:51 pm
Do a Type= Twolevel Basic where the variables you think are between-level varying only are not specified as between level and see if their Within-level variances are zero. If they are not, investigate each cluster to search for the variation.
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