jasp-stats / jasp-issues

This repository is solely meant for reporting of bugs, feature requests and other issues in JASP.
55 stars 29 forks source link

[Feature Request]: MLR Estimator for CFA/SEM #1484

Open PaulGinns opened 2 years ago

PaulGinns commented 2 years ago

Description

Request to expand the estimators available for CFA/SEM

Purpose

No response

Use-case

No response

Is your feature request related to a problem?

The MLR estimator is not available

Describe the solution you would like

Make all estimators available in lavaan available through JASP

Describe alternatives that you have considered

No response

Additional context

Hello,

would it be possible to expand the range of CFA/SEM estimators in JASP? At present, the "robust" estimators aren't provided (see https://lavaan.ugent.be/tutorial/est.html ) - MLR is a reasonably widely used estimator under non-normality that would be really good to have, particularly for measurement invariance testing.

Thanks in advance for considering this request.

JMBKoch commented 2 years ago

This feature is already available, although I understand the confusion. The MLR estimator is basically the ML estimator with robust standard errors. Hence, if you chose "ML" as estimator and the "robust" error calculation, that corresponds to the MLR estimator.

PaulGinns commented 2 years ago

Thanks very much for this clarification.

hm-arch commented 1 year ago

Dear JMB Koch, When I compare the MLR output in R to Jasp this does not seem to be the case. Even though I select the ML and the robust in JASP the CFI is the same whereas in R it is different when I use the MLR estimator. Any advice you have would be great. Thanks

hm-arch commented 1 year ago

FOR EXAMPLE

lavaan 0.6-9 ended normally after 21 iterations

Estimator ML Optimization method NLMINB Number of model parameters 25

Number of observations 1371

Model Test User Model: Standard Robust Test Statistic 369.508 268.999 Degrees of freedom 53 53 P-value (Chi-square) 0.000 0.000 Scaling correction factor 1.374 Yuan-Bentler correction (Mplus variant)

Model Test Baseline Model:

Test statistic 4480.485 3137.501 Degrees of freedom 66 66 P-value 0.000 0.000 Scaling correction factor 1.428

User Model versus Baseline Model:

Comparative Fit Index (CFI) 0.928 0.930 Tucker-Lewis Index (TLI) 0.911 0.912

Robust Comparative Fit Index (CFI) 0.932 Robust Tucker-Lewis Index (TLI) 0.916

Loglikelihood and Information Criteria:

Loglikelihood user model (H0) -26495.925 -26495.925 Scaling correction factor 1.423 for the MLR correction
Loglikelihood unrestricted model (H1) NA NA Scaling correction factor 1.389 for the MLR correction

Akaike (AIC) 53041.850 53041.850 Bayesian (BIC) 53172.432 53172.432 Sample-size adjusted Bayesian (BIC) 53093.017 53093.017

Root Mean Square Error of Approximation:

RMSEA 0.066 0.055 90 Percent confidence interval - lower 0.060 0.049 90 Percent confidence interval - upper 0.072 0.060 P-value RMSEA <= 0.05 0.000 0.085

Robust RMSEA 0.064 90 Percent confidence interval - lower 0.056 90 Percent confidence interval - upper 0.072

Standardized Root Mean Square Residual:

SRMR 0.041 0.041

juliuspfadt commented 1 year ago

I think you are right. in lavaan, MLR does not only produce robust standard errors but also a robust test statistic. se = robust does only produce robust standard errors.

areeq1 commented 1 year ago

Dear JMB Koch, When I compare the MLR output in R to Jasp this does not seem to be the case. Even though I select the ML and the robust in JASP the CFI is the same whereas in R it is different when I use the MLR estimator. Any advice you have would be great. Thanks

Excellent observation. We appreciate the effort to implement MLR (Not only for standard error of the estimates).

hm-arch commented 1 year ago

Ah Great news, thank you for all the effort with the Program!