Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix the default missing handling, add estimators #235

Merged
merged 3 commits into from
Oct 16, 2024
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion DESCRIPTION
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ Package: jaspFactor
Type: Package
Title: Factor Module for JASP
Version: 0.19.0
Date: 2023-04-14
Date: 2024-08-19
Author: JASP Team
Website: jasp-stats.org
Maintainer: JASP Team <[email protected]>
Expand Down
224 changes: 136 additions & 88 deletions R/confirmatoryfactoranalysis.R

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion inst/help/ConfirmatoryFactorAnalysis.md
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ JASP allows the factors in turn to be indicators of a second-order factor. This
### Advanced
-------
- Emulation: Emulate results from different software
- Error calculation: Change how standard errors for the parameters are computed
- Error calculation: Change how standard errors for the parameters are computed, if bootstrap the CIs are percentile bootstrap type
- Estimator: change the estimator for the CFA (Auto: ML if only scale variables used, WLS otherwise)
- Standardization: display standardized parameters for different standardization schemes
- Missing data handling: change the missing data handling method.
Expand Down
21 changes: 21 additions & 0 deletions inst/help/forQml/tooltipEstimators.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@

### Help on Estimators
Some of the estimators come with options that are set in the background:

- Estimators without extra effects (standard errors and model test are standard):
- ML, GLS, WLS, ULS, DWLS, DLS

- Extensions of ML-estimators with extra effects:
- MLM: classic robust se (se="robust.sem"), Satorra-Bentler test statistic (test="satorra.bentler")
- MLMV: classic robust se, scaled and shifted test statistic (test="scaled.shifted")
- MLMVS: classic robust se, mean and var adjusted Satterthwaite style test statistic (test="mean.var.adjusted")
- MLF: first-order standard se (information="first.order"), standard test
- MLR: Huber-White robust se (se="robust.huber.white"), Yuan-Bentler T2-star test statistic (test="yuan.bentler.mplus")

- Others:
- WLSM: implies DWLS with scaled test and robust se
- WLSMV: implies DWLS with mean and var adjusted test and robust se
- ULSM: implies ULS with scaled test and robust se
- ULSMV: implies ULS with mean-var adjusted test and robust se

- Note: If you specify "Standard errors" instead of leaving it at default the corresponding options set by the estimators in the background will be overwritten
112 changes: 68 additions & 44 deletions inst/qml/ConfirmatoryFactorAnalysis.qml
Original file line number Diff line number Diff line change
Expand Up @@ -102,8 +102,8 @@ Form
label: qsTr("Model identification")
name: "modelIdentification"
values: [
{ label: qsTr("Factor variances"), value: "factorVariance" },
{ label: qsTr("Marker variable"), value: "markerVariable" },
{ label: qsTr("Factor variances"), value: "factorVariance" },
{ label: qsTr("Effects coding"), value: "effectsCoding" }
]
}
Expand Down Expand Up @@ -206,64 +206,88 @@ Form
Section
{
title: qsTr("Advanced")
RadioButtonGroup
{
title: qsTr("Mimic package")
name: "packageMimiced"
RadioButton { label: qsTr("Lavaan"); value: "lavaan" ; checked: true }
RadioButton { label: qsTr("Mplus") ; value: "Mplus" }
RadioButton { label: qsTr("EQS") ; value: "EQS" }
}

Group
{
title: qsTr("Error calculation")
CIField { text: qsTr("CI level"); name: "ciLevel" }
RadioButtonGroup
Group {
DropDown
{
title: qsTr("Standard error")
name: "seType"
RadioButton { label: qsTr("Standard"); value: "standard"; checked: true}
RadioButton { label: qsTr("Robust"); value: "robust" }
RadioButton {
label: qsTr("Bootstrap")
value: "bootstrap"
IntegerField {
label: qsTr("Bootstrap samples")
name: "bootstrapSamples"
defaultValue: 1000
min: 100
max: 1000000
}
name: "packageMimiced"
label: qsTr("Mimic")
values: [
{ label: qsTr("Lavaan"), value: "lavaan" },
{ label: qsTr("Mplus"), value: "mplus" },
{ label: qsTr("EQS"), value: "eqs" }
]
}
RowLayout
{
DropDown
{
name: "estimator"
label: qsTr("Estimator")
id: estimator
values: [
{ label: qsTr("Default"), value: "default" },
{ label: qsTr("ML"), value: "ml" },
{ label: qsTr("GLS"), value: "gls" },
{ label: qsTr("WLS"), value: "wls" },
{ label: qsTr("ULS"), value: "uls" },
{ label: qsTr("DWLS"), value: "dwls" },
{ label: qsTr("DLS"), value: "dls" },
{ label: qsTr("PML"), value: "pml" },
{ label: qsTr("MLM"), value: "mlm" },
{ label: qsTr("MLMV"), value: "mlmv" },
{ label: qsTr("MLMVS"), value: "mlmvs" },
{ label: qsTr("MLF"), value: "mlf" },
{ label: qsTr("MLR"), value: "mlr" },
{ label: qsTr("WLSM"), value: "wlsm" },
{ label: qsTr("WLSMV"), value: "wlsmv" },
{ label: qsTr("ULSM"), value: "ulsm" },
{ label: qsTr("ULSMV"), value: "ulsmv" }
]
}
HelpButton
{
toolTip: qsTr("Click for more information")
helpPage: "forQml/tooltipEstimators"
}
}
}

RadioButtonGroup
{
title: qsTr("Estimator")
name: "estimator"
RadioButton { label: qsTr("Auto") ; value: "default"; checked: true }
RadioButton { label: qsTr("ML") ; value: "maximumLikelihood" }
RadioButton { label: qsTr("GLS") ; value: "generalizedLeastSquares" }
RadioButton { label: qsTr("WLS") ; value: "weightedLeastSquares" }
RadioButton { label: qsTr("ULS") ; value: "unweightedLeastSquares" }
RadioButton { label: qsTr("DWLS") ; value: "diagonallyWeightedLeastSquares" }
}

DropDown
DropDown
{
label: qsTr("Standard errors")
name: "seType"
id: errorCalc
values: [
{ label: qsTr("Default"), value: "default" },
{ label: qsTr("Standard"), value: "standard" },
{ label: qsTr("Robust"), value: "robust" },
{ label: qsTr("Bootstrap"), value: "bootstrap" }
]
}
IntegerField
{
visible: errorCalc.value == "bootstrap"
name: "bootstrapSamples"
label: qsTr(" Bootstrap samples")
defaultValue: 1000
min: 100
max: 1000000
}
CIField { text: qsTr(" CI level"); name: "ciLevel" }

DropDown
{
name: "naAction"
label: qsTr("Missing data handling")
values:
[
{ label: qsTr("FIML") , value: "fiml" },
{ label: qsTr("Listwise deletion") , value: "listwise" },
{ label: qsTr("FIML") , value: "fiml" },
{ label: qsTr("Pairwise") , value: "pairwise" },
{ label: qsTr("Two-stage") , value: "twoStage" },
{ label: qsTr("Robust two-stage") , value: "twoStageRobust" },
]
}
}

RadioButtonGroup
{
Expand Down
14 changes: 13 additions & 1 deletion po/R-ja.po
Original file line number Diff line number Diff line change
@@ -1,17 +1,29 @@
msgid ""
msgstr ""
"Project-Id-Version: jaspFactor 0.13.0\n"
<<<<<<< HEAD
"POT-Creation-Date: 2024-07-13 03:29\n"
"PO-Revision-Date: 2024-07-02 15:09+0000\n"
"Last-Translator: Daiki Hojo <[email protected]>\n"
"Language-Team: Japanese <https://hosted.weblate.org/projects/jasp/jaspfactor-"
"r/ja/>\n"
=======
"POT-Creation-Date: 2023-05-08 16:33\n"
"PO-Revision-Date: 2024-06-24 10:09+0000\n"
"Last-Translator: 上野真翔 <[email protected]>\n"
"Language-Team: Japanese <https://hosted.weblate.org/projects/jasp/"
"jaspfactor-r/ja/>\n"
>>>>>>> 1eb6579 (Translated using Weblate (Japanese) (#229))
"Language: ja\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: nplurals=1; plural=0;\n"
<<<<<<< HEAD
"X-Generator: Weblate 5.7-dev\n"
=======
"X-Generator: Weblate 5.6-rc\n"
>>>>>>> 1eb6579 (Translated using Weblate (Japanese) (#229))

msgid "Second-Order"
msgstr "二次"
Expand Down Expand Up @@ -334,7 +346,7 @@ msgid "Average variance extracted"
msgstr "平均分散抽出"

msgid "AVE"
msgstr "AVE"
msgstr ""

msgid "Heterotrait-monotrait ratio"
msgstr "Heterotrait-monotrait 比"
Expand Down
Loading
Loading