Path analysis failing to converge

59 views
Skip to first unread message

Ava Buxton

unread,
Jul 28, 2026, 10:46:46 AMJul 28
to lav...@googlegroups.com
Hello all!

I am conducting a path analysis X->M->Y->Y2, with paths from:
X->M (a)
M->Y (b)
X->Y (c)
Y->Y2 (d)

X and M are continuous. Y and Y2 are binary (0/1).

This is my model:
model <- '
  M ~ a*X
  Y ~ b*M + c*X
  Y2 ~ d*Y
  ab := a*b
  total := c + ab
  '

This is my current code for fitting the model:
fit <- sem(model, data = data, se = "bootstrap", bootstrap = 5000, iseed = 1)

And then for viewing the results:
summary(fit, fit.measures = TRUE, standardized = TRUE, rsquare = TRUE)

I saw that for dealing with categorical/binary variables, I need to include ordered = c("Y", "Y2") and estimator = "DWLS" when fitting.
I attempted this, but the model did not "converge". When inquiring, I found the Y/Y2 may be too associated, which may have caused this. The variables are similar, so this might make sense. Could this be it, or may there be another reason? Should I change the arguments I am using or add new ones? I saw another user on a forum who suggested including parameterization = "theta". Would this make sense to include?

Thank you!
Ava

Andrzej Szymkowiak

unread,
Aug 14, 2026, 11:18:38 AMAug 14
to lavaan
A non-converging path model with categorical observed variables is often a data or estimation problem rather than a syntax problem. I would diagnose it before changing convergence tolerances.

First, inspect the marginal frequencies and the relevant 2 × 2 tables. A zero or very small cell, an almost constant variable, or an almost deterministic relationship can make a tetrachoric correlation approach ±1. The resulting correlation matrix may be non-positive definite, and the model may fail even when it is identified on paper.

Because Y and Y2 are binary endogenous variables, declare them explicitly and use an ordinal estimator:

fit <- lavaan::sem(
  model,
  data = data,
  ordered = c("Y", "Y2"),
  estimator = "WLSMV"
)

Do not use the ordinary nonparametric bootstrap with WLSMV. Also note that theta parameterisation will not solve separation, sparse cells, or an almost deterministic Y → Y2 relationship.

I would then build the model in stages: fit the M regression, fit Y on X and M, inspect the Y/Y2 table, add Y2, and only then add defined indirect effects. Check the exact warnings, convergence status, coverage, extreme thresholds, large standard errors, and non-positive-definite matrices. If Y almost perfectly predicts Y2, the problem is in the information available in the data, not the iteration limit.

Finally, a*b in this model is an indirect effect on the latent-response/probit scale. It should not automatically be interpreted as a probability-scale causal indirect effect. If you share the exact warning, sample size, marginal counts, Y × Y2 table and model output, the failing part can be diagnosed more precisely.
Reply all
Reply to author
Forward
0 new messages