-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Powerlaws #18
Powerlaws #18
Conversation
Check out this pull request on See visual diffs & provide feedback on Jupyter Notebooks. Powered by ReviewNB |
lcs/generative.py
Outdated
@@ -128,3 +123,31 @@ def clustered_unipartite(n_groups, n_ind, my_p_dist, my_g_dist, **kwargs): | |||
B = bipartite_graph(edge_list) | |||
U = nx.projected_graph(B, projected_nodes) # create unipartite projection | |||
return nx.adjacency_matrix(U).todense() | |||
|
|||
|
|||
def truncated_power_law_configuration(n, x_min, x_max, r, seed=None): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think because we're doing so much post-processing, we could probably just modify this algo a little bit.
lcs/generative.py
Outdated
G = nx.configuration_model(degree_sequence) | ||
G = nx.Graph(G) | ||
G.remove_edges_from(nx.selfloop_edges(G)) | ||
return G |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This should return a matrix.
A new branch for testing PS on configuration models.