# Difference between latent and observed variable in SEM

If I run a structural equation model (SEM) (all variables are metric scale)

x -> z
y -> z
x -> y


it's basically like running three separate regression models. There are three equations to describe the whole model. What happens/changes (mathematically), if x becomes a latent variable X, that is measured by x?

Would also be interested in texts that explain this.

The model, as drawn, isn't identified. You need to constrain the loading from the latent x (I've called it Fx) to x to be 1, and the error variance for x must be zero.

If you add these two constraints, the two models are identical.

Here's some R code.

library(lavaan)
set.seed(1234)
d <- data.frame(x = rnorm(1000),
y = rnorm(1000),
z = rnorm(1000))

m1 <- "z ~ x + y
y ~ x"

f1 <- sem(m1, data = d)

m2 <- "z ~ Fx + y
y ~ Fx
Fx =~ 1 * x"

f2 <- sem(m2, data = d)

summary(f1)
summary(f2)


And here's the output:

> summary(f1)
lavaan (0.5-23.1097) converged normally after  11 iterations

Number of observations                          1000

Estimator                                         ML
Minimum Function Test Statistic                0.000
Degrees of freedom                                 0

Parameter Estimates:

Information                                 Expected
Standard Errors                             Standard

Regressions:
Estimate  Std.Err  z-value  P(>|z|)
z ~
x                 0.018    0.032    0.551    0.582
y                -0.037    0.033   -1.130    0.259
y ~
x                 0.056    0.031    1.794    0.073

Variances:
Estimate  Std.Err  z-value  P(>|z|)
.z                 1.022    0.046   22.361    0.000
.y                 0.959    0.043   22.361    0.000

> summary(f2)
lavaan (0.5-23.1097) converged normally after  11 iterations

Number of observations                          1000

Estimator                                         ML
Minimum Function Test Statistic                0.000
Degrees of freedom                                 0

Parameter Estimates:

Information                                 Expected
Standard Errors                             Standard

Latent Variables:
Estimate  Std.Err  z-value  P(>|z|)
Fx =~
x                 1.000

Regressions:
Estimate  Std.Err  z-value  P(>|z|)
z ~
Fx                0.018    0.032    0.551    0.582
y                -0.037    0.033   -1.130    0.259
y ~
Fx                0.056    0.031    1.794    0.073

Variances:
Estimate  Std.Err  z-value  P(>|z|)
.x                 0.000
.z                 1.022    0.046   22.361    0.000
.y                 0.959    0.043   22.361    0.000
Fx                0.994    0.044   22.361    0.000

>


If you make the latent equivalent to the measured variable, the latent becomes the measured variable, and the models are the saem.

I don't (off the top of my head) know of any textbook that explains it. It the old days of lisrel (20+ years ago) you needed to use this trick to fit things like MIMIC models. It's not necessary any more.

• I would be really interested in getting some explanation about the sentence "If you make the latent equivalent to the measured variable, the latent becomes the measured variable, and the models are the same". Does this mean replacing the latent variable with the mix of measurements which follow from the model? Related question: stats.stackexchange.com/questions/573978/…
– Tom
Commented May 4, 2022 at 10:01
• I mean (or think I meant, I wrote this a while ago), if you have only one indicator on a latent variable, the latent variable IS (probably) the measured variable, and is redundant. Commented May 5, 2022 at 15:45