static.fitness.game (no.of.edges, fitness.out, fitness.in,
loops = FALSE, multiple = FALSE)
NULL
(the default), the generated graph
will be undirected. If not NULL
, then it should be a numeric
vector and it specifies the in-fitness of each vertex. If this argument is not NULL
, then a directe
degree.sequence.game
instead.
This model is commonly used to generate static scale-free networks. To
achieve this, you have to draw the fitness scores from the desired power-law
distribution. Alternatively, you may use
static.power.law.game
which generates the fitnesses for
you with a given exponent.N <- 10000
g <- static.fitness.game(5*N, sample((1:50)^-2, N, replace=TRUE))
degree.distribution(g)
plot(degree.distribution(g, cumulative=TRUE), log="xy")
Run the code above in your browser using DataLab