Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

PCAnet

PCAnet


Description

Convenience function for converting a qgraph object to a layout determined by principal components analysis

Usage

PCAnet(qgraph_net, cormat, varTxt = F, repulse = F, repulsion = 1,
  principalArgs = list(), ...)

Arguments

qgraph_net

an object of type qgraph

cormat

the correlation matrix of the relevant data. If this argument is missing, the function will assume that the adjacency matrix from qgraph_net is a correlation matrix

varTxt

logical. Print the variance accounted for by the PCA in the lower left corner of the plot

repulse

logical. Add a small repulsion force with wordcloud package to avoid node overlap?

repulsion

scalar for the repulsion force (if repulse=T). Larger values add more repulsion

principalArgs

additional arguments in list format passed to psych::principal

...

additional arguments passed to qgraph

Details

A network plotted with PCA can be interpreted based on coordinate placement of each node. A node in the top right corner scored high on both the first and second principal components

References

Jones, P. J., Mair, P., & McNally, R. J. (2018). Visualizing psychological networks: A tutorial in R. Frontiers in Psychology, 9, 1742. https://doi.org/10.3389/fpsyg.2018.01742


networktools

Tools for Identifying Important Nodes in Networks

v1.2.3
GPL-3
Authors
Payton Jones [aut, cre]
Initial release
2020-4-19

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.