to static-networks
ask links [die]
ask turtles[
ask turtles with[who > [who] of myself][
if random-float 1.0 < prob-ER [
create-link-with one-of other turtles[
ask links [ set color blue
]
]]]]
end
to timevaring-networks
reset-ticks
let select n-of active other turtles
ask select [
let chosen n-of m other turtles
create-links-with chosen [
set color red
]
]
我对一堆节点同时生成两种边,一种静态边,不随时间改变。一种时序边,每个时间步要删除上个时间步建立的边,再重新建立。
那么我该怎么删除已经生成的呢?用ask links [die]会把静态边也删掉块
ask links [die]
ask turtles[
ask turtles with[who > [who] of myself][
if random-float 1.0 < prob-ER [
create-link-with one-of other turtles[
ask links [ set color blue
]
]]]]
end
to timevaring-networks
reset-ticks
let select n-of active other turtles
ask select [
let chosen n-of m other turtles
create-links-with chosen [
set color red
]
]
我对一堆节点同时生成两种边,一种静态边,不随时间改变。一种时序边,每个时间步要删除上个时间步建立的边,再重新建立。
那么我该怎么删除已经生成的呢?用ask links [die]会把静态边也删掉块