Adding an edge by vertices indices?

Is it possible to add an edge between a source and a target using their
indices?

attachment.html (107 Bytes)

It would be nice if you would look at the documentation before posting
to the list.

You should just do g.add_edge(i, j), where i and j are integers.

Best,
Tiago

Sorry for the annoyance, but from the documentation I understood that I
have to pass vertices objects than integers. Sorry again.

attachment.html (938 Bytes)

That is fine. Looking again, the documentation is not so clear on
this.

Best,
Tiago