如何更改netlogo中特定链接数的种类?

时间:2016-09-21 05:43:01

标签: hyperlink netlogo

我正在开发项目,我需要使用breed = active链接创建特定数量的链接,其余链接是非活动链接。代码如下

 ask nodes
  [
   create-inactive-links-to other nodes
    [ 
      hide-link
      let num-links count links
      set msg-passing-freq ( num-links * percentage-links / 100 )
      ask n-of msg-passing-freq inactive-links [
          set breed active-links
          show-link
        ]
    ]
  ]
 layout
end

它显示一个错误,表明已经存在与x-turtle和y-turtles的链接作为活动链接

0 个答案:

没有答案