Rgraphviz - neato layout - edge weights have no effect
1
0
Entering edit mode
@franz-quehenberger-1864
Last seen 9.6 years ago
Dear all, neato makes layouts according to a physical model in which the length of the edges is determined by springs. The weight of the edge is the strength of the spring. However, I was not able to find any influence of edge weight on the layout. In the http://www.graphviz.org/Documentation/neatoguide.pdf the attribute "len" is another parameter of the neato layout. set.seed(31) V=letters[1:5] g2=randomEGraph(V,0.5) plot(g2,"neato",main="All weights 1","All weights are 1.") # change and edge weight edgeData(g2, from = "d", to = "e", attr = "weight") <- 20 plot(g2,"neato",main="Nothing changed!") #try out length attribute change edgeDataDefaults(g2,"len")=1 edgeData(g2, from = "d", to = "e", attr = "len") <- 5 plot(g2,"neato",main="Nothing changed again!") Has anyone an idea how to achieve a change in the graph layout ? Best Franz Quehenberger -- Institute for Medical Informatics, Statistics and Documentation Graz, Austria
graph graph • 1.3k views
ADD COMMENT
0
Entering edit mode
@lilongisb-sibch-1725
Last seen 9.6 years ago
> Dear all, > > neato makes layouts according to a physical model in which the length of > the edges is determined by springs. The weight of the edge is the > strength of the spring. However, I was not able to find any influence of > edge weight on the layout. In the > http://www.graphviz.org/Documentation/neatoguide.pdf the attribute "len" > is another parameter of the neato layout. > > set.seed(31) > V=letters[1:5] > g2=randomEGraph(V,0.5) > plot(g2,"neato",main="All weights 1","All weights are 1.") > > # change and edge weight > edgeData(g2, from = "d", to = "e", attr = "weight") <- 20 > plot(g2,"neato",main="Nothing changed!") > > #try out length attribute change > edgeDataDefaults(g2,"len")=1 > edgeData(g2, from = "d", to = "e", attr = "len") <- 5 > plot(g2,"neato",main="Nothing changed again!") > > > Has anyone an idea how to achieve a change in the graph layout ? > > Best > > Franz Quehenberger > -- > Institute for Medical Informatics, Statistics and Documentation > Graz, Austria > > _______________________________________________ > Bioconductor mailing list > Bioconductor at stat.math.ethz.ch > https://stat.ethz.ch/mailman/listinfo/bioconductor > Search the archives: > http://news.gmane.org/gmane.science.biology.informatics.conductor >
ADD COMMENT

Login before adding your answer.

Traffic: 1087 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6