0

I wanted to run a path analysis but could not report the RMSEA and its p-value. The results showed that RMSEA = 0.00 Confidence interval = 0.00 and p-value: NA. I wonder what it does mean.

In my analysis, I have four IVs and three DVs. This is the code what I wanted to run:

model1 <-"ML_NC+ML_NS+Preventive ~ TPE+covidconcern+MisinfoEx+CorrectAction"

fit_analysis1 <- sem(model1, data = dataset2)
summary(fit_analysis1, fit.measures=TRUE, standardized=T,rsquare=T)

And also, if I want to include the control variables and mediating variables in the path analysis, how do I add these?

This is the results.

lavaan 0.6-12 ended normally after 15 iterations

  Estimator                                         ML
  Optimization method                           NLMINB
  Number of model parameters                        18

  Number of observations                           272

Model Test User Model:
                                                      
  Test statistic                                 0.000
  Degrees of freedom                                 0

Model Test Baseline Model:

  Test statistic                               419.201
  Degrees of freedom                                15
  P-value                                        0.000

User Model versus Baseline Model:

  Comparative Fit Index (CFI)                    1.000
  Tucker-Lewis Index (TLI)                       1.000

Loglikelihood and Information Criteria:

  Loglikelihood user model (H0)               -849.964
  Loglikelihood unrestricted model (H1)       -849.964
                                                      
  Akaike (AIC)                                1735.928
  Bayesian (BIC)                              1800.833
  Sample-size adjusted Bayesian (BIC)         1743.759

Root Mean Square Error of Approximation:

  RMSEA                                          0.000
  90 Percent confidence interval - lower         0.000
  90 Percent confidence interval - upper         0.000
  P-value RMSEA <= 0.05                             NA

Standardized Root Mean Square Residual:

  SRMR                                           0.000

Parameter Estimates:

  Standard errors                             Standard
  Information                                 Expected
  Information saturated (h1) model          Structured

Regressions:
                   Estimate  Std.Err  z-value  P(>|z|)   Std.lv  Std.all
  ML_NC ~                                                               
    TPE               0.208    0.044    4.700    0.000    0.208    0.247
    covidconcern      0.113    0.054    2.083    0.037    0.113    0.121
    MisinfoEx         0.298    0.053    5.609    0.000    0.298    0.309
    CorrectAction     0.205    0.066    3.107    0.002    0.205    0.186
  ML_NS ~                                                               
    TPE               0.183    0.040    4.633    0.000    0.183    0.245
    covidconcern      0.128    0.049    2.648    0.008    0.128    0.155
    MisinfoEx         0.272    0.048    5.713    0.000    0.272    0.317
    CorrectAction     0.130    0.059    2.205    0.027    0.130    0.132
  Preventive ~                                                          
    TPE               0.073    0.052    1.410    0.159    0.073    0.068
    covidconcern      0.610    0.064    9.578    0.000    0.610    0.509
    MisinfoEx        -0.105    0.063   -1.686    0.092   -0.105   -0.085
    CorrectAction     0.300    0.077    3.870    0.000    0.300    0.211

Covariances:
                   Estimate  Std.Err  z-value  P(>|z|)   Std.lv  Std.all
 .ML_NC ~~                                                              
   .ML_NS             0.295    0.034    8.642    0.000    0.295    0.615
   .Preventive        0.008    0.038    0.198    0.843    0.008    0.012
 .ML_NS ~~                                                              
   .Preventive        0.053    0.034    1.540    0.123    0.053    0.094

Variances:
                   Estimate  Std.Err  z-value  P(>|z|)   Std.lv  Std.all
   .ML_NC             0.535    0.046   11.662    0.000    0.535    0.744
   .ML_NS             0.429    0.037   11.662    0.000    0.429    0.752
   .Preventive        0.739    0.063   11.662    0.000    0.739    0.623

R-Square:
                   Estimate
    ML_NC             0.256
    ML_NS             0.248
    Preventive        0.377

This is data structure, and this is the results

enter image description here

> dput(head(dataset2))
structure(list(ID = 1:6, Demo = c(1L, 1L, 3L, 3L, 5L, 1L), Gender = c(2L, 
1L, 2L, 1L, 2L, 1L), Ethnicity = c(6L, 1L, 2L, 1L, 4L, 3L), Education = c(2L, 
3L, 4L, 2L, 6L, 3L), Income = c(1L, 1L, 6L, 5L, 4L, 3L), Poli = c(1, 
3, 2, 2, 2, 3), covidconcern = c(4.33333333333333, 4, 5, 5, 5, 
2.33333333333333), TPEm = c(4.8, 5, 5, 5, 4.8, 2.8), TPEo = c(5, 
5, 5, 5, 4.8, 3.6), TPE = c(0.2, 0, 0, 0, 0, 0.8), MisinfoEx = c(4, 
4.83333333333333, 5, 4, 4.66666666666667, 4.16666666666667), 
    CorrectAction = c(3.6, 5, 5, 4.6, 4.8, 4.4), ML_NC = c(3.83333333333333, 
    4, 5, 4.5, 4.83333333333333, 5), ML_NS = c(4, 4.4, 5, 4.6, 
    4.6, 5), ML = c(3.91666666666667, 4.2, 5, 4.55, 4.71666666666667, 
    5), Preventive = c(4, 4.75, 4.75, 3.75, 5, 4.5)), row.names = c(NA, 
-6L), class = c("data.table", "data.frame"), .internal.selfref = <pointer: 0x7f90cc83e2e0>)
>

Thank you.

Haehae
  • 1
  • 2
  • Can you provide your data using `dput(dataset2)` to make your post [reproducible](https://stackoverflow.com/questions/5963269/how-to-make-a-great-r-reproducible-example)? – jrcalabrese Jan 07 '23 at 01:38
  • for some reason, I cannot data using dput(). All variables in the code are continuous variables – Haehae Jan 07 '23 at 21:47
  • What error message do you get when you try to use `dput(dataset2)`? – jrcalabrese Jan 07 '23 at 22:17
  • I just got the structure of dataset2. Do you want the results? I cannot post everything here in the comment. – Haehae Jan 07 '23 at 22:21
  • Yes, posting your data using `dput()` is the [recommended way of sharing data](https://stackoverflow.com/questions/5963269/how-to-make-a-great-r-reproducible-example). You can potentially use `head(dput())` to provide a portion of your data, but I'm not sure if it would fully replicate the error in your question. – jrcalabrese Jan 07 '23 at 22:28
  • I add in the posting – Haehae Jan 07 '23 at 22:57
  • Posting images of data is not [reproducible](https://stackoverflow.com/questions/5963269/how-to-make-a-great-r-reproducible-example), as StackOverflow users can't diagnose problems just from an image. When you use `dput(head(dataset2))`, please copy and paste the output that appears in your console (it'll start with the term `structure`) into your question. – jrcalabrese Jan 07 '23 at 23:05
  • the code in the previous comment, head(dput()), was not working to post. I added the working code in the posting. – Haehae Jan 07 '23 at 23:30

0 Answers0