Specifying sample design

81 views
Skip to first unread message

Miguel Ángel Cruz Posadas

unread,
Sep 13, 2024, 12:00:15 AM9/13/24
to lavaan
I am estimating a measurement model and my database comes from a national survey, I have the variables survey weights, primary sampling unit and stratum; is it correct to use the options sampling.weights for survey weights and cluster for psu? Is there another option to specify the strata survey?

By the way, my data is categorical.

Thank you very muhc in advance.

Terrence Jorgensen

unread,
Sep 16, 2024, 3:42:47 AM9/16/24
to lavaan
I have survey weights, primary sampling unit and stratum; is it correct to use the options sampling.weights for survey weights and cluster for psu? 

Yes, those are the correct lavaan() arguments to use.

Is there another option to specify the strata survey?
 
The lavaan.survey package additionally allows for strata.

By the way, my data is categorical.

That combination of features is available in Mplus, but neither lavaan nor lavaan.survey allows for survey weights with categorical outcomes.  

Terrence D. Jorgensen    (he, him, his)
Assistant Professor, Methods and Statistics
Research Institute for Child Development and Education, the University of Amsterdam
http://www.uva.nl/profile/t.d.jorgensen


Stas Kolenikov

unread,
Sep 17, 2024, 3:47:41 PM9/17/24
to lav...@googlegroups.com
Modeling of latent variables with categorical outcomes (isn't that just IRT??) with complex survey data features is also feasible in Stata via -svy: gsem-, although it won't go into the voodoo of fit indices.

-- Stas Kolenikov, PhD, PStat (ASA, SSC) 
-- Principal Statistician, NORC @NORCnews
-- Opinions stated in this email are mine only, and do not reflect the position of my employer
-- Social media: @StatStas [ Twitter | mastodon.online ]
-- http://stas.kolenikov.name



--
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/fe57d9b1-5a9b-41ee-870b-2bbdc69d9826n%40googlegroups.com.

Miguel Ángel Cruz Posadas

unread,
Oct 1, 2024, 12:47:14 AM10/1/24
to lavaan
Hello, Terrence.

Thank you for answering my questions.

I am using the compRelSEM  function to calculate McDonald's omega, but I have a question: I estimated a measurement model with dichotomous variables where I specify the calculation of the error covariance of two manifest variables, how does this affect the calculation of the omega of McDonald's? is this technically possible?

If it helps, here is the code:

p_22ns<-read_dta("pobreza_22ns_cv.dta")
mmmp_ud_mi <- ' p =~ ic_rezedu + ic_asalud + ic_segsoc + ic_cv + ic_sbv + ic_ali_nc + plp
ic_asalud ~~ ic_segsoc'
fitmmmp_ud22_mi <- sem(mmmp_ud_mi, data = p_22ns,
                    ordered=TRUE,
                    std.lv=TRUE)
summary(fitmmmp_ud22_mi, fit.measure=TRUE, ci=TRUE, rsquare= T)
compRelSEM(fitmmmp_ud22_mi)

Kind regards.

Terrence Jorgensen

unread,
Oct 2, 2024, 6:27:18 AM10/2/24
to lavaan
I am using the compRelSEM  function to calculate McDonald's omega

This is not related to the original post.  In the future, please create a new post with a "Subject" that makes sense.

I specify the calculation of the error covariance of two manifest variables, how does this affect the calculation of the omega of McDonald's? is this technically possible?

Yes, omega can still be calculated.  See the formulas provided on the help page.
Reply all
Reply to author
Forward
0 new messages