Python implementation of the LAGO method for dynamic community detection in temporal networks. Derived functions such as the Longitudinal Modularity are also provided.
Project description
Dynamic Community Detection
This repository compiles methods and experiments related to community structures in temporal networks.
The current code corresponds to the pre-print Longitudinal Modularity, a Modularity for Link Streams.
Example
To compute the Longitudinal Modularity of a dynamic community structure on a temporal network:
import longitudinal_modularity_tools as lmt
longitudinal_modularity = get_longitudinal_modularity(
time_links_df=time_links_df,
# (pd.DataFrame) Interactions table. Columns: source, target, time, source_commu, target_commu
communities_df=communities_df,
# (pd.DataFrame): Nodes communities memberships. Columns: node, time, commu
expectation=expectation,
# (str, optional): Logitudinal expectation type. Must be "cm" for co-membership, "jm" for joint membership, or "mm" for mean membership. Defaults to "mm".
omega=omega,
# (float, optional): Time penalty weigth. High values will favor continuous communities. Defaults to 1.
)
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distributions
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file dcd_lago-1.0.0-py3-none-any.whl.
File metadata
- Download URL: dcd_lago-1.0.0-py3-none-any.whl
- Upload date:
- Size: 9.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.7.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
02626e9b32103a54632dd75752d270ff55fdd4fad74e1fe30eb2a44f9a35affe
|
|
| MD5 |
248363d05fb85af1994f36f39e58c1eb
|
|
| BLAKE2b-256 |
6961d0c124d21ed1b18495475068d919dd7c758b8db4aa795619404acbd1f924
|