G=networkx.Graph()
G.add_node(1,lat=40.5,long=42.5)
#or
G.add_node(1,pos=(40.5,42.5))
print G.node[1]
{'lat': 40.5, 'long': 42.5, 'pos': (45.5, 42.5)}
You might also take a look at the following thread that talks
about using matplotlib to draw the nodes on a map:
http://groups.google.com/group/networkx-discuss/browse_thread/thread/f52bff0b3eb0b086
Dan
Is there any routine in here that can generate two (connected or no) random
graph connected by a path?
In a similar way as for the function
"barbell_graph(m1, m2, create_using=None)"
I need K_{m1} be two random graph of the same size not necessary identical,
for example two erdos_renyi or two barabasi albert,
Cheers
----- Message d'origine ----
De : Dan Schult <dsc...@colgate.edu>
À : networkx...@googlegroups.com
Envoyé le : Lun 3 janvier 2011, 15h 00min 09s
Objet : Re: [networkx-discuss] nodes with lat and long
Dan
--
You received this message because you are subscribed to the Google Groups
"networkx-discuss" group.
To post to this group, send email to networkx...@googlegroups.com.
To unsubscribe from this group, send email to
networkx-discu...@googlegroups.com.
For more options, visit this group at
http://groups.google.com/group/networkx-discuss?hl=en.
Dan
I set it to m2=1, and visualise the graph, I have two set of random graph but no
path connecting them,
Cheers
----- Message d'origine ----
De : Dan Schult <dsc...@colgate.edu>
À : networkx...@googlegroups.com
Envoyé le : Lun 3 janvier 2011, 15h 39min 24s
Objet : Re: [networkx-discuss] two random graph connected by a path