View source: R/community.unidimensional.R
community.unidimensional | R Documentation |
A function to apply several approaches to detect a unidimensional community in
networks. There have many different approaches recently such as expanding
the correlation matrix to have orthogonal correlations ("expand"
),
applying the Leading Eigenvalue community detection algorithm
cluster_leading_eigen
to the correlation matrix
("LE"
), and applying the Louvain community detection algorithm
cluster_louvain
to the correlation matrix ("louvain"
).
Not necessarily intended for individual use – it's better to use EGA
community.unidimensional(
data,
n = NULL,
corr = c("auto", "cor_auto", "pearson", "spearman"),
na.data = c("pairwise", "listwise"),
model = c("BGGM", "glasso", "TMFG"),
uni.method = c("expand", "LE", "louvain"),
verbose = FALSE,
...
)
data |
Matrix or data frame. Should consist only of variables that are desired to be in analysis |
n |
Numeric (length = 1).
Sample size if |
corr |
Character (length = 1).
Method to compute correlations.
Defaults to
For other similarity measures, compute them first and input them
into |
na.data |
Character (length = 1).
How should missing data be handled?
Defaults to
|
model |
Character (length = 1).
Defaults to
|
uni.method |
Character (length = 1).
What unidimensionality method should be used?
Defaults to
|
verbose |
Boolean.
Whether messages and (insignificant) warnings should be output.
Defaults to |
... |
Additional arguments to be passed on to
|
Returns the memberships of the community detection algorithm. The memberships will output regardless of whether the network is unidimensional
Hudson Golino <hfg9s at virginia.edu> and Alexander P. Christensen <alexpaulchristensen@gmail.com>
Expand approach
Golino, H., Shi, D., Christensen, A. P., Garrido, L. E., Nieto, M. D., Sadana, R., Thiyagarajan, J. A., & Martinez-Molina, A. (2020).
Investigating the performance of exploratory graph analysis and traditional techniques to identify the number of latent factors:
A simulation and tutorial.
Psychological Methods, 25, 292-320.
Leading Eigenvector approach
Christensen, A. P., Garrido, L. E., Guerra-Pena, K., & Golino, H. (2023).
Comparing community detection algorithms in psychometric networks: A Monte Carlo simulation.
Behavior Research Methods.
Louvain approach
Christensen, A. P. (2023).
Unidimensional community detection: A Monte Carlo simulation, grid search, and comparison.
PsyArXiv.
# Load data
wmt <- wmt2[,7:24]
# Louvain with Consensus Clustering (default)
community.unidimensional(wmt)
# Leading Eigenvector
community.unidimensional(wmt, uni.method = "LE")
# Expand
community.unidimensional(wmt, uni.method = "expand")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.