SPREADER"))))
dummy_1 <- which(V(g)$compartment[w]=="IGNORANT")"
which I solved by adding the following line of code:
" dummy_1 <- w[dummy_1]".
Once I added the previous line of code, I solved the indexing problem I had with the "dummy_1" vertex.
This time it seems to be slightly different, because I start from:
"dummy_2 <- which(V(g)$compartment=="SPREADER")"
Do you have any suggestion on how I can, this time, deal with the indexing problem of the "dummy_2" vertex?
obviously, this time I cannot add the comand "dummy_2 <- w[dummy_2]" because I have not a "w" vector to use.
Thanks! Giorgio