I am using igraph "0.7.1" from R interface. I noticed that when I read a graph 
in GraphML, an additional id attribute is created for nodes in the igraph 
graph, even if there exists no GraphML id attribute for nodes. This might 
create problems if there exists already an id attribute for nodes in the igraph 
graph. An example follows.

Best,

Massimo

# load igraph
library(igraph)

# create a ring graph
g = graph.ring(10)

# create id attribute
V(g)$id = 1:vcount(g)

# save the graph in GraphML
write.graph(g, file="ring.xml", format="graphml")

# read the graph
g = read.graph(file="ring.xml", format="graphml")

Warning message:
  In .Call("R_igraph_read_graph_graphml", file, as.numeric(index),  :
             At foreign-graphml.c:443 :Could not add vertex ids, there is 
already an 'id' vertex attribute



_______________________________________________
igraph-help mailing list
[email protected]
https://lists.nongnu.org/mailman/listinfo/igraph-help

Reply via email to