File tree Expand file tree Collapse file tree 1 file changed +2
-2
lines changed
Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -44,7 +44,7 @@ It restrain the rule evaluation to all those nodes for which the attribute "Sex"
4444 import random
4545 import ndlib.models.ModelConfig as mc
4646 import ndlib.models.CompositeModel as gc
47- import ndlib.models.compartments.NodeCategoricalAttribute as ns
47+ import ndlib.models.compartments as cpm
4848
4949 # Network generation
5050 g = nx.erdos_renyi_graph(1000 , 0.1 )
@@ -62,7 +62,7 @@ It restrain the rule evaluation to all those nodes for which the attribute "Sex"
6262 model.add_status(" Removed" )
6363
6464 # Compartment definition
65- c1 = na .NodeCategoricalAttribute(" Sex" , " male" , probability = 0.6 )
65+ c1 = cpm .NodeCategoricalAttribute(" Sex" , " male" , probability = 0.6 )
6666
6767 # Rule definition
6868 model.add_rule(" Susceptible" , " Infected" , c1)
You can’t perform that action at this time.
0 commit comments