Closed debmalya191 closed 5 years ago
Thanks for the report.
Instead of print(EoN.Simulation_Investigation.node_status(G,(0,0),1))
, use print(sim.node_status((0,0),1))
to get the status of node (0,0)
at time 1
.
The sim
object you created above has all of the information about the simulation you did.
(note, I'll be traveling later this week and next so I'll be slow to respond if you have more support requests).
I have a graph G=nx.grid_2d_graph(m,m,periodic=True). When I try to run -
G=nx.grid_2d_graph(m,m,periodic=True) initial_infections = [(u,v) for (u,v) in G if u==int(m/2) and v==int(m/2)] sim = EoN.basic_discrete_SIR(G,0.5,initial_infecteds = initial_infections, return_full_data=True, tmax = 25) print(EoN.Simulation_Investigation.node_status(G,(0,0),1))
it gives the error-
File "D:\anaconda\lib\site-packages\EoN\simulation_investigation.py", line 108, in node_status changetimes = self._nodehistory[node][0] AttributeError: 'Graph' object has no attribute '_nodehistory'