| efa_cd | R Documentation |
Factor retention method introduced by Ruscio and Roche (2012). The code was adapted from the CD code published by Auerswald and Moshagen (2019), available at https://osf.io/x5cz2/.
efa_cd(
x,
n_factors_max = NA,
N_pop = 10000,
N_samples = 500,
alpha = 0.3,
cor_method = c("pearson", "spearman", "kendall", "poly", "tetra"),
max_iter = 50
)
x |
data.frame or matrix. Dataframe or matrix of raw data. |
n_factors_max |
numeric. The maximum number of factors to test against. Larger numbers will increase the duration the procedure takes, but test more possible solutions. If left NA (default) the maximum number of factors for which the model is still over-identified (df > 0) is used. |
N_pop |
numeric. Size of finite populations of comparison data. Default is 10000. |
N_samples |
numeric. Number of samples drawn from each population. Default is 500. |
alpha |
numeric. The alpha level used to test the significance of the improvement added by an additional factor. Default is .30. |
cor_method |
character. One of |
max_iter |
numeric. The maximum number of iterations after which the
iterative PAF procedure inside the comparison-data generation is halted; it
does not cap an EFA of |
Comparison data (CD) extends parallel analysis by reproducing the observed correlation matrix rather than generating random data: datasets with a known factor structure are generated with an increasing number of factors, and the smallest number for which adding a further factor no longer significantly improves the reproduction of the observed eigenvalues is retained (Ruscio & Roche, 2012).
Because it reproduces the observed correlation structure instead of a null model,
CD was among the more accurate criteria across a broad range of conditions in
Ruscio and Roche (2012). It is, however, the only criterion in this family that
requires raw data, and by some margin the most computationally intensive one: a
finite population of N_pop cases is generated and N_samples samples are drawn
from it at every candidate factor count. It is therefore a good choice when the
raw data are at hand and the runtime is acceptable, and a poor one for a quick
look at a correlation matrix.
The comparison data are obtained by simulation, so the suggested number of factors
varies slightly from run to run. Call base::set.seed() beforehand to make a run
reproducible.
Note that if the data contains missing values, these will be removed for the
comparison data procedure using stats::na.omit(). If
missing data should be treated differently, e.g., by imputation, do this outside
efa_cd() and then pass the complete data.
An object of class efa_retention (see print.efa_retention() and
plot.efa_retention() for the print and plot methods). Its main fields are:
n_factors |
A named numeric vector ( |
results |
A list with a single record holding the mean RMSE between the
eigenvalues of the generated and the entered data per number of factors
(used for the plot) and, in |
settings |
A list of the settings used. |
Auerswald, M., & Moshagen, M. (2019). How to determine the number of factors to retain in exploratory factor analysis: A comparison of extraction methods under realistic conditions. Psychological Methods, 24(4), 468–491. https://doi.org/10.1037/met0000200
Ruscio, J., & Roche, B. (2012). Determining the number of factors to retain in an exploratory factor analysis using comparison data of known factorial structure. Psychological Assessment, 24, 282–292. doi: 10.1037/a0025697
efa_retain() as a wrapper function for this and the other factor
retention criteria.
Other factor retention criteria:
efa_ekc(),
efa_hull(),
efa_kgc(),
efa_map(),
efa_nest(),
efa_parallel(),
efa_retain(),
efa_scree(),
efa_smt()
# determine n factors of the GRiPS
efa_cd(GRiPS_raw, N_pop = 500, N_samples = 20)
# determine n factors of the DOSPERT risk subscale
efa_cd(DOSPERT_raw, N_pop = 500, N_samples = 20)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.