I have a erdos-renyi game with 6000 nodes and probability 0.003.

g1 = erdos.renyi.game(6000, 0.003)

How to create a Watts Strogatz game with the same probability.

g1 = watts.strogatz.game(1, 6000, ?, ?)
What should be the third and fourth parameter to this argument.

According to ?watts.strogatz.game help file (in the igraph package?), the four arguments to this function are:
dim     Integer constant, the dimension of the starting lattice.
size     Integer constant, the size of the lattice along each dimension.
nei Integer constant, the neighborhood within which the vertices of the lattice will be connected.
p         Real constant between zero and one, the rewiring probability.

So it looks like the last two should be neighborhood and rewiring probability respectively.

______________________________________________
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.

Reply via email to