bctpy
bctpy copied to clipboard
module_degree_zscore directed version wrong?
Here is the MATLAB version comments:
flag, 0, undirected graph (default)
% **1, directed graph: out-degree**
% **2, directed graph: in-degree**
% 3, directed graph: out-degree and in-degree
This is bctpy version:
# flag : int
# Graph type. 0: undirected graph (default)
# **1: directed graph in degree**
# **2: directed graph out degree**
# 3: directed graph in and out degree
Notice that they use different flag. And for py version, it transposes connection matrix for OUT DEGREE. I look up the code and found we use NP.SUM AXIS=1 which means it applies row-wise summation, so it's made for OUT DEGREE, so maybe do not need transposition?
I test 2 version using same dataset. I think it is wrong, the comment for py version should be changed.