[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[igraph] read.graph query
From: |
Thomas |
Subject: |
[igraph] read.graph query |
Date: |
Fri, 21 Sep 2012 10:44:20 +0100 |
When I write out and then read in a graph, it's average path length
changes - code and output below. Anyone know why this is happening?
I'm running iGraph on R.
>g <- watts.strogatz.game(1,500,5,0.1)
>g <- simplify(g, remove.multiple = TRUE, remove.loops = TRUE)
> transitivity(g)
[1] 0.3620622
> average.path.length(g)
[1] 3.514822
> write.graph(g, "SmallWorldEL.txt", format=c("edgelist"))
> h <- read.graph("SmallWorldEL.txt", format=c("edgelist"))
> average.path.length(h)
[1] 4.872057
> transitivity(h)
[1] 0.3620622
Thank you,
Thomas
This message and any attachment are intended solely for the addressee and may
contain confidential information. If you have received this message in error,
please send it back to me, and immediately delete it. Please do not use, copy
or disclose the information contained in this message or in any attachment.
Any views or opinions expressed by the author of this email do not necessarily
reflect the views of the University of Nottingham.
This message has been checked for viruses but the contents of an attachment
may still contain software viruses which could damage your computer system:
you are advised to perform your own checks. Email communications with the
University of Nottingham may be monitored as permitted by UK legislation.
- [igraph] read.graph query,
Thomas <=