Saving a graph in Pajek with color attributes
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
igraph |
Confirmed
|
Undecided
|
Gábor Csárdi |
Bug Description
I tried to save a simple graph in Pajek format with defined color values, but I get the following error message:
> g <- graph.ring(10)
> V(g)$color <- "red"
> write.graph(g, format="pajek", file="C:
Error in write.graph.
At rinterface.c:761 : No such attribute, Invalid value
Error during wrapup:
>
I found the list archives, and found some hints to update to the most recent version of igraph. I've just updated to igraph_0.5.5-3 rj_0.5.5-4, but still no change.
I've also tried some alternatives like using set.vertex.
Based on the documentation I found in ?read.graph, there are two tables stating that the color values should work (if I got it right).
My sessionInfo() output:
> sessionInfo()
R version 2.12.1 (2010-12-16)
Platform: x86_64-
locale:
[1] LC_COLLATE=
[3] LC_MONETARY=
[5] LC_TIME=
attached base packages:
[1] stats graphics grDevices utils datasets methods base
other attached packages:
[1] igraph_0.5.5-3 rj_0.5.5-4
loaded via a namespace (and not attached):
[1] tools_2.12.1
Tamás Nepusz pointed out at the igraph mailing list that I may have stumbled upon a bug, because the code is even worse on Mac OS X:
> library(igraph)
g <> g <- graph.ring(10)
> V(g)$color <- "red"
> V(g)$color
[1] "red" "red" "red" "red" "red" "red" "red" "red" "red" "red"
> write.graph(g, format="pajek", file="test.net")
*** caught segfault ***
address 0x8, cause 'memory not mapped'
Traceback:
1: .Call("
2: write.graph.
3: write.graph(g, format = "pajek", file = "test.net")
He said that this is 0.6 (not 0.5.x), and it looks like the bug has been around for a while.
Changed in igraph: | |
status: | New → Confirmed |
assignee: | nobody → Gábor Csárdi (gabor.csardi) |
The development of igraph has moved to github, so please do not comment on this bug here. You are of course welcome to comment on github, here: /github. com/igraph/ igraph/ issues/ 446
https:/