Skip to main content

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

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

dcd_lago-1.0.0-py3-none-any.whl (9.8 kB view details)

Uploaded Python 3

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

Hashes for dcd_lago-1.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 02626e9b32103a54632dd75752d270ff55fdd4fad74e1fe30eb2a44f9a35affe
MD5 248363d05fb85af1994f36f39e58c1eb
BLAKE2b-256 6961d0c124d21ed1b18495475068d919dd7c758b8db4aa795619404acbd1f924

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page