Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • Error when using medsem command in simultaneous group SEM estimation

    Hi all,

    I am running a between groups SEM with multiple mediators. In one group there is a significant indirect effect. To determine which mediator is contributing to this indirect effect, I was attempting to use the medsem command. I did the following:

    1) installed the medsem package using, "scc install medsem, replace"
    2) ran my group SEM with the correct level of invariance
    3) then ran the command for the first mediator, "medsem, indep(X) med(M) dep(Y)" - where X, M, Y, are all latent variables within the SEM. However when I run the command I get the error, "Y:M not found r(111)".

    Any help would be greatly appreciated! I have used this command before, and didn't run into any problems, so am wondering if it something about the group level analysis.
    Last edited by William McClanahan; 10 Sep 2019, 07:18. Reason: Edited to include tags

  • #2
    You'll increase your chances of a useful answer by following the FAQ on asking questions - Stata code in code delimiters, readable Stata output, sample data using dataex. It looks like there is an incompatibility between your SEM and medsem, but you didn't post the code for your sem.

    With a user-written routine, you often don't get the level of generality that Stata might include. It certainly looks like your SEM specification included a group variable and medsem is not ready to interpret such specifications.

    Comment

    Working...
    X