Closed JolandaKossakowski closed 5 years ago
Hi Jolanda,
Both scale and include are arguments to centralityPlot
not centralityTable
, which now treats these as networks leading to the error. In centralityTable the argument standardized = FALSE
can be used. It will return all centrality indices, and you can filter them manually afterward (e.g., using dplyrs filter function).
would be awesome if the error could reflect this in a future update!
The latest version of qgraph returns an error when I want to compute the raw centrality measures, or if I want to include certain centrality measures.
MWE:
library(psych) library(qgraph) library(bootnet)
data(bfi) bfiSub <- bfi[,1:25]
Estimate network:
Network <- estimateNetwork(bfiSub, default = "EBICglasso") centralityTable(Network) # works centralityTable(Network, scale = "raw") #error : Error in UseMethod("getWmat") : no applicable method for 'getWmat' applied to an object of class "character" centralityTable(Network, include = c("Strength")) # same error are above