briatte/ggnet

node.group is not correct after setting subset.threshold

qsz13 opened this issue · 1 comments

qsz13 commented

Hi,
after setting the subset.threshold, the group of the nodes seem not correct, here is the code I tested:
n= network(35,directed=FALSE)
type <- sample(1:2, 35, replace=T)
names(type) <- seq(1,35)
ggnet(n,node.group=type,label.nodes = TRUE,subset.threshold =0)
ggnet(n,node.group=type,label.nodes = TRUE,subset.threshold =2)

the group is:
screen shot 2015-08-27 at 10 52 49 am

this is the result and the color of some nodes are not correct such as 8, 10, 18 :
screen shot 2015-08-27 at 10 51 18 am
screen shot 2015-08-27 at 10 47 43 am

Yep, that's a bug.