|
From: | Gábor Csárdi |
Subject: | Re: [igraph] Generate bipartite graph with specified degree distribution [Again] |
Date: | Mon, 20 May 2013 10:35:38 -0400 |
But I haven't resolved the problem yet because is required that the sum out-degree and in-degree be the same even number.Please, take a look at my example:users = 1000items = 500usersDegs = sample(1:items, size=items, replace=TRUE, prob=(1:items)^-2)itemsDegs = sample(1:users, size=users, replace=TRUE, prob=(1:users)^-2)g <- degree.sequence.game(out.deg = c(usersDegs, rep(0, items)), in.deg = c(rep(0, users), itemsDegs))It's very unlikely have that required sum using sample from a specified distribuition.
Is there a way to use degree.sequence.game with sampling from a distribution?
Is there another function to achieve this?
[Prev in Thread] | Current Thread | [Next in Thread] |