Questions tagged [lavaan]

`lavaan` is the LAtent VAriable ANalysis package in R used for structural equation modeling

Filter by
Sorted by
Tagged with
3 votes
1 answer
24 views

Why do I get smaller degrees of freedom for the Scalar invariance model than the Metric one while testing measurement invariance?

I am trying to test the measurement invariance in my bi-factor model with CFA tests. I have 23 binary questions coded "correct" and "incorrect" and 3 different groups in my data. ...
Enes Bayrakoglu's user avatar
0 votes
1 answer
36 views

Comparing regression coefficients across non-nested SEM models (Lavaan)

I had question about SEM in Lavaan which I cannot seem to get a grip on through any google forums or my old lecture slides... I wish to explain cognition using several variables (CR1/CR2, which stand ...
SEMdummy's user avatar
3 votes
1 answer
36 views

Completely standardized indirect effect (Preacher & Kelley, 2011) in lavaan

Preacher & Kelley (2011) have proposed an effect size (i.e., completely standardized indirect effect) that quantifies the magnitude of an indirect effect. My question is whether lavaan's ...
Matthias's user avatar
2 votes
1 answer
78 views

Getting an equivalent of R-squared for simple univariate regression done with structural equation modeling

I need to calculate a very simple regression model outcome ~ predictor. To treat missings, I have to use FIML and also I need bootstrapping. Since the ...
Madamadam's user avatar
  • 197
1 vote
1 answer
40 views

Question- How to read the CFA results using the ordered statement in Lavaan package for ordinal data?

I am using the ordered statement in my CFA model when running lavaan in R, but I couldn't figure out how to read the results. I ...
user avatar
0 votes
0 answers
18 views

Approach for multivariate outlier detection when treating missing values with FIML

I‘m calculating a simple regression with one predictor and one dependent variable. Missings treatment is done with full information maximum likelihood (FIML). Should I do outlier detection, i.e. ...
Madamadam's user avatar
  • 197
1 vote
1 answer
43 views

Moderation and Mediation model

I am trying to fit a moderation mediation model (please see the figure) So I have a clasic mediation model and a moderator for the association between the mediator and the outcome. I want to fit this ...
JuanJMV's user avatar
  • 11
3 votes
0 answers
52 views

I get very different and inconsistent model fit indices and test statistics every time I run the cfa.mi models with the same imputed categorical data

I am trying to test the measurement invariance in my one-latent-factor model. I have 24 questions coded "correct" and "incorrect" and 3 different groups in my data. The sample ...
Enes Bayrakoglu's user avatar
1 vote
0 answers
17 views

Assumptions to be met for a contrast test of mean against zero

When doing a contrast test (see R code below) or it's rather unusual regression style equivalent, both of which are basically a t-test, what assumptions have to be ...
Madamadam's user avatar
  • 197
2 votes
1 answer
74 views

Comparing path analysis models: mediation vs. (residual) covariance

I am using lavaan to run path analysis to predict PC from WA and LC. These are multi-group models. Described here is the first step (identifying best-fitting paths); it is followed by constraining ...
Jeanne Sinclair's user avatar
1 vote
0 answers
140 views

Can I covary exogenous and endogenous latent variables in SEM in lavaan

I am editing the question as it was too meandering. I am sorry about that. I am running an extended Theory of planned behavior (TPB) model of digital piracy and I have a question that boils down to - ...
Miljan's user avatar
  • 11
0 votes
0 answers
28 views

Can we use multiple ordinal endogeneous variables in SEM model using lavaan?

I have three endogenous variables each measured using 5-point likert scale ranging from Strongly Agree to Strongly Disagree. I want to use SEM for my analysis using Lavaan. All the examples I have ...
ros's user avatar
  • 1
2 votes
1 answer
52 views

Using FIML (Full Information Maximum Likelihood) for simple correlation test on data with missings?

I have a dataset with missing values. Since my main hypothesis is just a simple regression, my adviser told me to use FIML regression. So I used lavaan package: ...
Madamadam's user avatar
  • 197
2 votes
1 answer
61 views

Seeking References for Mediation and SEM Best Practices

Preamble Recently, a colleague approached me with a dataset$^1$ that they wanted to use to compare several competing mediation models using structural equation modeling (SEM). The models are simple, e....
Preston Botter's user avatar
1 vote
0 answers
38 views

What does it mean when the total effect is non-significant in a mediation?

I ran a mediation analysis using lavaan, there was a significant indirect effect but no significant direct or total effect. What does the total effect mean and how do I go about interpreting this ...
stats student's user avatar
1 vote
0 answers
40 views

power analysis for cross-lagged panel model with random intercept using powRICLPM

I want to compute power analysis for cross-lagged panel model with random intercept using powRICLPM package (Related publication) Authors of the package did a great job and the power analysis seems to ...
David's user avatar
  • 11
1 vote
0 answers
225 views

lavaan: std.lv versus std.all interpretation for (essentially) tau-equivalent models

A (essentially) tau-equivalent model has the following specifications: the factor loadings are constrained to be equal the intercepts are constrained to be equal (tau-equivalent) or allowed to vary ...
hanna-without-h's user avatar
0 votes
0 answers
34 views

How do different sets of restrictions in a SEM with moderation affect results?

I'm trying to run a latent moderated mediation analysis SEM with R lavaan. It is essentially "First Stage Moderation", per Edwards & Lambert (2007), with a few extra factors. I'm using ...
Chris's user avatar
  • 33
3 votes
1 answer
153 views

How to interpret standardized simple slopes and indirect effects in R with semTools and lavaan?

I am attempting to obtain a standardized solution for simple slopes and indirect effects in a SEM in R using lavaan and semTools::probe2WayMC, following the methods of Schoemann & Jorgensen (2021) ...
Chris's user avatar
  • 33
0 votes
0 answers
41 views

Fixed Effects in a latent variable framework using lavaan

I am just now familiarising myself with the literature on Fixed Effect Models. I was wondering if anyone had any references or could confirm that fixed effect models can be used in a latent variable ...
Garry's user avatar
  • 11
0 votes
1 answer
152 views

Centering variables in Lavaan - Path analysis

I hope you're doing well. I'm currently knee-deep in path analysis using the lavaan package for my research. My analysis involves moderation, and centering the variables may simplify coefficient ...
Ronald Bahamondes-Álvarez 's user avatar
2 votes
2 answers
68 views

Test of Group Invariance with 3 Groups

Say, we have three groups and we want to run a test of group invariance with the following data. ...
thanmour's user avatar
1 vote
1 answer
21 views

Lavaan: How to free a constraint in one group out of two, while at the same time using effects-coding scaling method?

I am examining differences in latent means between two groups using the following syntax: ...
Nikos Makrygiorgos's user avatar
0 votes
2 answers
422 views

Should I interpret the scaled or the standard model in SEM (lavaan)?

I'm attempting to fit a structural equation model in lavaan. My model looks like this: ...
Flóra F.'s user avatar
0 votes
1 answer
110 views

Serial mediation with 3 mediators and 2 predictors [lavaan]

I have constructed a structural equation model in R using lavaan, with 2 exogenous predictor variables, 3 mediators, and 1 endogenous response variable: I tried to label it as conventionally as ...
Atanaqui's user avatar
1 vote
1 answer
65 views

Interpertation of a conditional quadratic latent growth curve model (i.e., with predictors)

I have a conditional quadratic latent growth curve model and am wondering how to interpret the results. My predictor of interest is significantly associated with the slope factor (B = -0.45, p = .001) ...
Aepkr's user avatar
  • 189
1 vote
1 answer
131 views

Latent growth curve model: should you include predictors if the variance for slope and/or intercept factor is not significant?

Hi I am running a series of latent growth curve models. I am wondering: can predictors of the slope and intercept factor(s) be included when the slope and/or intercept variance are not significant, or ...
Aepkr's user avatar
  • 189
0 votes
0 answers
42 views

semPower: Accounting for Clustered Standard Errors in SEM Power Analysis with Fixed Effects Model

I am planning to analyse clustered data with a structural equation model and as I am planning on submitting my project as a registered report, I am first trying to do an in-depth power analysis (it is ...
Maximilian's user avatar
2 votes
1 answer
109 views

Latent growth curve model: The variance-covariance matrix of the estimated parameters (vcov) does not appear to be positive definite

I have run a latent growth curve model in R using lavaan and got the below warning. It would be good to hear suggestions on how to resolve this warning. The full output is below. Note that I dummy-...
Aepkr's user avatar
  • 189
1 vote
0 answers
66 views

Lavaan and semTools partial measurement invariance syntax

I am running measurement invariance in Lavaan using a 7 item ordinal scale. I have been using Lavaan and semTools, and specifically the measEq.syntax command, due to the fact it easily implements Wu ...
Josh Blake's user avatar
3 votes
1 answer
202 views

R lavaan: quadratic regression of latent variables

Is there a way of specifying a quadratic regression between latent variables in lavaan? (Or in another R package for structural equation modeling?) That is, latent variable y, ...
John K. Kruschke's user avatar
3 votes
1 answer
211 views

Effect of robust maximum likelihood estimator in structural equation modelling when data is normal?

I understand that when data are nonnormal robust maximum likelihood estimator can be used. I'm wondering are there any disadvantages of using a robust maximum likelihood estimator when the data are ...
Aepkr's user avatar
  • 189
0 votes
1 answer
80 views

Measurement invariance: Model fit increases with increasing constraints

I have run into the same problem repeatedly, namely that model fit increases with increasing model restraints. I want to compare measurement invariance on a three-factor model (based on previous CFAs ...
Viktoria Birkenæs's user avatar
3 votes
1 answer
73 views

Structural equation modeling (latent growth models): robust estimators to handle outliers?

Can I use robust estimators (e.g., "MLM" and "MLR"estimator lavaan options) to overcome outliers within my sample, or should I remove outliers? For context, I am modelling the ...
Aepkr's user avatar
  • 189
0 votes
2 answers
136 views

Structural equation modelling in lavaan [closed]

I used factor analysis and structural equation modelling using lavaan in RStudio. Before adding the residual covariances and regression into the SEM model, the ...
Suba's user avatar
  • 3
2 votes
1 answer
427 views

Goodness of fit of structural equation modelling

I am currently working on a structural equation modeling project using the lavaan package in R. The model satisfied all the goodness of fit tests (GFI, AGFI, CFI, ...
Suba's user avatar
  • 21
1 vote
0 answers
98 views

Mediation analysis (lavaan in R vs. Hayes MACRO SPSS) [closed]

I have a really basic question when conducting mediation analysis. When reading articles, some scholars use lavaan package in R and other use Hayes MACRO. Are there any differences? For example, if I ...
noone's user avatar
  • 43
4 votes
1 answer
200 views

Can you run a SEM on a correlation matrix only (without a covariance matrix)?

I have access to correlations between my variables of interest and the overall sample size. But I don't have standard deviations so I can't construct a covariance matrix. Can I still run a SEM on the ...
JRB's user avatar
  • 431
3 votes
1 answer
67 views

Lavaan growth model: to treat endogenous variable as ordinal or continuous

I am modelling the trajectories of scores on two cognitive tests (i.e., PAL and SOS) measured at four time points. To do this I am creating separate latent growth curve models for each cognitive test, ...
Aepkr's user avatar
  • 189
1 vote
0 answers
22 views

Serial multiple mediated model in lavaan not calculating standard errors, Z-values, and P values for defined parameters

I am trying to run the following model in Lavaan, in which AM, RM, and CU are latent variables. It also has three control variables (CV1, CV2, and CV3). I have written the code that is included at ...
Cecilia Sada's user avatar
3 votes
0 answers
269 views

How should I specify a multi-level moderated mediation in lavaan?

I have a repeated measures crossover design where two treatments were delivered to all participants, and measurements of the mediator M and outcome Y were taken following each treatment. I also have a ...
Ben Smith's user avatar
1 vote
0 answers
163 views

Interaction between two binary variables in lavaan

I have two binary variables (X1 and X2, coded 0/1) as predictors in a growth model in lavaan. I want to understand their individual contributions and their ...
Jeanne Sinclair's user avatar
0 votes
1 answer
80 views

Which effects to fix in SEM with two time points?

I am trying to fit a (to me relatively complex) SEM where I'm interested in two dependent variables measured at t2 and assume that this is explained through independent variables at t1. I have never ...
ineednewsocks's user avatar
1 vote
0 answers
319 views

NA in lavaan output for Standard Errors (Std.Err), z-value, and p-value (P(>|z|))

unfortunately I have a problem with my lavaan output in R Studio (Version R-4.3.0). I would be very grateful to get help with my problem! I do not get standard errors, z and p values displayed. For ...
raintwo's user avatar
  • 11
0 votes
0 answers
67 views

Binary and count variables as endogenous variables

I set up an APIM (actor-partner interdependence model) in R (lavaan). No I'm facing the following issues: Model: My endogenous variable is a count variable that follows a poisson-distribution. Model:...
Juli's user avatar
  • 1
0 votes
1 answer
113 views

Interpretation of lavaan growth covariate parameters (effects on intercept and slope)

I am trying to interpret the output of the growth command with regressors. Here's the command, and the covariates are dummy coded 0/1: ...
Jeanne Sinclair's user avatar
0 votes
1 answer
64 views

Error with mediation analysis in lavaan in R

I am beginner to run mediation analysis using lavaan package in r and have some issues to run the models and understand errors. Here is my syntax. ...
Trebit14's user avatar
2 votes
3 answers
137 views

Why do matrices of simulation data generated in R create strongly related latent variables?

When creating examples of matrices for CFA in R for students, I still have a problem with getting data that looks realistic - specifically, that between latent variables I often have covariance path ...
kwadratens's user avatar
2 votes
0 answers
51 views

can someone explain the application of row.weights and sampling.weights in lavaan? [closed]

I am trying to include the weight derived from Inverse Probability of Treatment Weighting (IPTW) into a structural equation model (SEM). However, it is unclear how it should be incorporated into the ...
stat_ocean's user avatar
2 votes
1 answer
797 views

Covariates in mediation analysis

I have started working on mediation analysis, but I am still confusing how to deal with covariates. Here are my models (X, predictor; M, mediator; Y, outcome; all are linear regression models). Path 1:...
Trebit14's user avatar

1
2 3 4 5
8