Closed elisabettabiondi closed 1 month ago
Since I am not able to reopen the issue, I open a new one here.
Sorry, my bad. Indeed, you can't re-open it, but I could after commenting. Anyway, doesn't matter, we can continue the discussion here.
Once I run:
optimiser = la.Optimiser() diff = optimiser.optimise_partition_multiplex([part_pos, part_neg], layer_weights=[1, -1])
You can retrieve the membership from part_pos
and part_neg
(both contain the same partitioning information). These are objects that are derived from igraph.VertexClustering
, see that documentation for more information.
Perfect, thank you! Is there a way to force the partition to be of length 2?
I found the answer by myself in this previous issue: https://github.com/vtraag/leidenalg/issues/89#issuecomment-964054798
Great you found the answer!
One additional tip by the way, as explained in the documentation on optimise_partition_multiplex
, it might be better to set consider_comms
to leidenalg.ALL_COMMS
when dealing with negative links.
Thank you, @vtraag. Since I am not able to reopen the issue, I open a new one here. A simple question: Once I run:
how do I get the vertices belonging to each partition?
Originally posted by @vtraag in https://github.com/vtraag/leidenalg/issues/179#issuecomment-2134855565