Open tonante-BR opened 2 months ago
Hi @tonante-BR,
What is going on is that jasp treats the data as ordinal and R treats it as continuous. If you have them treat the data the same you get the same results. To replicate the results in your jasp file in R, do
Dados2 <- Dados
for (i in seq_along(Dados2)) {
Dados2[[i]] <- as.factor(Dados2[[i]])
}
Network2 <- estimateNetwork(Dados, default = "EBICglasso", weighted = TRUE, tuning = 0.5,
corMethod = "cor_auto")
centralityPlot(Network2, scale = c("z-scores"),
include = c("Strength","Closeness", "Betweenness"),
theme_bw = TRUE, print = TRUE,
verbose = TRUE, weighted = TRUE,
decreasing = T) +
ggplot2::scale_y_discrete(limits=rev)
To replicate the results from R in jasp, click these icons next to the variables
which opens a dropdown
and then you can change them to scale. In addition, change the Correlation method to Cor
.
Hope that helps!
This issue will be automatically closed in 42 days due to inactivity. Feel free to leave a comment if you believe this is still relevant.
JASP Version
0.19.0
Commit ID
No response
JASP Module
Network
What analysis are you seeing the problem on?
Classic Network
What OS are you seeing the problem on?
Windows 10
Bug Description
I ran a network analysis and noticed some differences in the results between JASP and R. For example, the number of non-zeros was different, as well as the centrality metrics. From what I observed, I followed the same settings in R as I did in JASP. I would like to know if there is indeed a difference or if I might be doing something differently between them. Attached are the JASP file, the R script, and the dataset I'm using. Thank you very much. PHQ.zip
Expected Behaviour
I expected to obtain the same metrics when performing the analysis in both JASP and R.
Steps to Reproduce
Log (if any)
No response
More Debug Information
No response
Final Checklist