问题描述
我有一个来自 igraph 包的网络列表(),我想对它们进行批量调整。这就是我要做的,采用单个网络图对象的格式。
# $Weight to E(nw)$weight
E(nw)$weight <- E(nw)$Weight
# edge weight to width
E(nw)$width <- 1+(log(E(nw)$weight)*6)
#arrow size
E(nw)$arrow.size <- .7
#figures
c.colours <- c("red","blue","green","yellow")[membership(nw.community)]
png(file = "... nw.png",width = 1800,height = 1200,units = "px")
plot(nw.community,nw,col = c.colours,mark.col = adjustcolor(c.colours,alpha.f = 0.4),mark.border = adjustcolor(c.colours,alpha.f = 1),edge.curved = .15)
dev.off()
我将如何编写一个函数来为列表对象执行此操作?我不太了解编写函数或循环。
解决方法
暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!
如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。
小编邮箱:dio#foxmail.com (将#修改为@)