igraph-help
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [igraph] How to avoid indexing issues with "which" fuction


From: Tamas Nepusz
Subject: Re: [igraph] How to avoid indexing issues with "which" fuction
Date: Thu, 8 Jun 2017 11:02:03 +0200

By the way, I probably exposed the algorithm in a wrong way (I don't speak english very well).
A given percentage of the whole vertices, are selected at the beginning of the algorithm to be "IMMUNE", and they will be immune all the time, so I expect to have the same percentage of nodes to be immune at the end of the algorithm, but some of these nodes passed from "immune" to "spreader" during the process.
I understand that, but the best that you can do at this stage is to print the state of each vertex and the set of relevant variables after each iteration of the loop, and then stop immediately when you find that one of your vertices went into the wrong state. Then you can look at the variables right before the incorrect state change and figure out what goes wrong where. This is what I would do anyway if I were you.

T.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]