Phi matrix vs. Psi matrix

335 views
Skip to first unread message

shamel...@queensu.ca

unread,
Jul 1, 2022, 5:33:58 AM7/1/22
to lavaan
When I run  lavInspect on the   HolzingerSwineford1939  (or any other )  dataset, it shows the LV correlations under the psi matrix, like this:

$psi
        visual textul speed
visual  1.000              
textual 0.459  1.000      
speed   0.471  0.283  1.000

Aren't these LV correlations supposed to be called the "phi" matrix and not the "psi" matrix? My understanding of the terminology (e.g., Bollen 1989) is that phi is for the covariances of the exogenous LV (here: visual, textual, speed), and psi is for the covariances of the disturbance terms for endogenous LVs (none here).    

Here is the code I used:
HS.model <- ' visual  =~ x1 + x2 + x3      
              textual =~ x4 + x5 + x6
              speed   =~ x7 + x8 + x9 '
fit <- cfa(HS.model, data = HolzingerSwineford1939)
lavInspect(fit, what="std.all", add.labels=T)

Edward Rigdon

unread,
Jul 2, 2022, 11:15:41 AM7/2/22
to lav...@googlegroups.com
     Back in 1989--more than 30 years ago now--the dominant framework was probably the old LISREL framework, which made distinctions between "the X side": and "the Y side" of the model. When computers were slower and computer time more precious, this may have produced some economies (because it made for smaller parameter matrices) and may have been "more familiar" to researchers with backgrounds in regression. More recently, more researchers have dropped the "X / Y" distinction. If the "Psi" matrix is the matrix of unexplained or unpredicted covariance among common factors, well, these factors have no predictors, so all of their variance is unexplained. But if you like, you can also think of this as a partitioned matrix:

"Psi" =  Phi    0
              0     Psi

Even after all this time, I don't think that anyone has written a better book about factor-based SEM than Bollen (1989).

--
You received this message because you are subscribed to the Google Groups "lavaan" group.
To unsubscribe from this group and stop receiving emails from it, send an email to lavaan+un...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/lavaan/d855bbb0-79e6-49e3-85f8-4bc7990195bfn%40googlegroups.com.

Shu Fai Cheung

unread,
Jul 2, 2022, 3:50:58 PM7/2/22
to lav...@googlegroups.com
Maybe related. I drafted a function a while ago for teaching and planned to include it somewhere, but I do not yet have time to do so. It prints the matrices in a lavaan model and shows to which parameter in the parameter table a matrix element corresponds to:


This is the output for the Holzinger-Swineford-1939 CFA model:

$lambda
             visual           textual           speed
x1 (visual=~x1 = 1)                 0               0
x2       visual=~x2                 0               0
x3       visual=~x3                 0               0
x4                0 (textual=~x4 = 1)               0
x5                0       textual=~x5               0
x6                0       textual=~x6               0
x7                0                 0 (speed=~x7 = 1)
x8                0                 0       speed=~x8
x9                0                 0       speed=~x9

$theta
       x1     x2     x3     x4     x5     x6     x7     x8     x9
x1 x1~~x1      0      0      0      0      0      0      0      0
x2      0 x2~~x2      0      0      0      0      0      0      0
x3      0      0 x3~~x3      0      0      0      0      0      0
x4      0      0      0 x4~~x4      0      0      0      0      0
x5      0      0      0      0 x5~~x5      0      0      0      0
x6      0      0      0      0      0 x6~~x6      0      0      0
x7      0      0      0      0      0      0 x7~~x7      0      0
x8      0      0      0      0      0      0      0 x8~~x8      0
x9      0      0      0      0      0      0      0      0 x9~~x9

$psi
                 visual          textual          speed
visual   visual~~visual  visual~~textual  visual~~speed
textual visual~~textual textual~~textual textual~~speed
speed     visual~~speed   textual~~speed   speed~~speed

This is for a model with structural paths (I modified the CFA model buy adding paths between the factors):

HS.model2 <- ' visual  =~ x1 + x2 + x3

               textual =~ x4 + x5 + x6
               speed   =~ x7 + x8 + x9
               speed ~ visual + textual'
fit_sem <- sem(HS.model2,
               data = HolzingerSwineford1939)
annotate_matrices(fit_sem)

$lambda
             visual           textual           speed
x1 (visual=~x1 = 1)                 0               0
x2       visual=~x2                 0               0
x3       visual=~x3                 0               0
x4                0 (textual=~x4 = 1)               0
x5                0       textual=~x5               0
x6                0       textual=~x6               0
x7                0                 0 (speed=~x7 = 1)
x8                0                 0       speed=~x8
x9                0                 0       speed=~x9

$theta
       x1     x2     x3     x4     x5     x6     x7     x8     x9
x1 x1~~x1      0      0      0      0      0      0      0      0
x2      0 x2~~x2      0      0      0      0      0      0      0
x3      0      0 x3~~x3      0      0      0      0      0      0
x4      0      0      0 x4~~x4      0      0      0      0      0
x5      0      0      0      0 x5~~x5      0      0      0      0
x6      0      0      0      0      0 x6~~x6      0      0      0
x7      0      0      0      0      0      0 x7~~x7      0      0
x8      0      0      0      0      0      0      0 x8~~x8      0
x9      0      0      0      0      0      0      0      0 x9~~x9

$psi
                 visual          textual        speed
visual   visual~~visual  visual~~textual            0
textual visual~~textual textual~~textual            0
speed                 0                0 speed~~speed

$beta
              visual       textual speed
visual             0             0     0
textual            0             0     0
speed   speed~visual speed~textual     0

It is for the unstandardized solution but the mapping is the same for the standardized solution.

Regards,
Shu Fai Cheung (張樹輝)


shamel...@queensu.ca

unread,
Jul 3, 2022, 10:12:49 AM7/3/22
to lavaan
Ed and Shu Fai: Thank you both for your insightful answers. They are very helpful.
Shamel

Yves Rosseel

unread,
Jul 3, 2022, 2:32:45 PM7/3/22
to lav...@googlegroups.com
lavaan uses the so-called 'LISREL all-y' notation by default. This
corresponds to LISREL submodel 3B. In this all-y model, all observed
variables ('x' or 'y') are collected in the y-vector, and all latent
variables are collected in the 'eta' vector. Despite being a 'submodel',
it is in fact (a bit) more general than the original LISREL model (as we
can for examample correlate the residual variances of 'x' and 'y'
variables).

According to the 'official' notation of LISREL submodel 3B, the
variance/covariance matrix of the latent variables is denoted by 'Psi'.
It contains both total (for exogenous) and residual (for endogenous)
variances and covariances of 'eta'.

Alternative notations are the 'Bentler-Weeks' notation, and the (many
variants of the) 'Recticular Action Meta-model' (RAM) representation.

In recent versions of lavaan, you can use the representation = "RAM"
argument to switch to a RAM representation, while the default is
representation = "LISREL".

Yves.
> --
> You received this message because you are subscribed to the Google
> Groups "lavaan" group.
> To unsubscribe from this group and stop receiving emails from it, send
> an email to lavaan+un...@googlegroups.com
> <mailto:lavaan+un...@googlegroups.com>.
> <https://groups.google.com/d/msgid/lavaan/d855bbb0-79e6-49e3-85f8-4bc7990195bfn%40googlegroups.com?utm_medium=email&utm_source=footer>.

Edward Rigdon

unread,
Jul 3, 2022, 2:56:33 PM7/3/22
to lav...@googlegroups.com
I really, really like this display! I think it will help many students.

shamel...@queensu.ca

unread,
Jul 4, 2022, 1:54:14 AM7/4/22
to lavaan
Hi Yves,
Thanks, the option to change the matrix representation is very useful. But when I fit a lavaan model using representation="RAM", I get an error: 
Error in computeVY(lavmodel = lavmodel, GLIST = GLIST, diagonal.only = TRUE) :
  only representation LISREL has been implemented for now

I am running the new versions of R (4.2.1) and lavaan (0.6.11)

Reply all
Reply to author
Forward
0 new messages