Skip to main content

bursty_dynamics is a Python package designed to facilitate the analysis of temporal patterns in longitudinal data. It provides functions to calculate the burstiness parameter (BP) and memory coefficient (MC), detect event trains, and visualise results.

Project description


Bursty Dynamics


|PyPI| |Documentation|

bursty_dynamics is a Python package designed to facilitate the analysis of temporal patterns in longitudinal data. It provides functions to calculate the burstiness parameter (BP) and memory coefficient (MC), detect event trains, and visualise results.

This package implements the alternate burstiness parameter described in the paper ‘Measuring Burstiness for Finite Event Sequences’ by Kim, Eun-Kyeong, and Hang-Hyun Jo, and memeory coefficient described in ‘Burstiness and Memory in Complex Systems’ by Goh, K.-I., and A.-L. Barabási.

Features

  • Burstiness Parameter (BP) and Memory Coefficient (MC) Calculation: Calculate BP and MC to quantify the irregularity and memory effects of event timing within longitudinal data.
  • Event Train Detection: Detect and label event trains based on user-defined criteria such as maximum inter-event time and minimum burst size.
  • Train-Level Analysis: Analyse BP and MC for detected event trains, providing insights into temporal patterns within trains of events.
  • Visualisation Tools: Visualise temporal patterns with scatter plots, histograms, kernel density estimates (KDE), and more, facilitating interpretation of analysis results.
  • User-Friendly Interface: Designed for ease of use, with clear function parameters and output formats, making it accessible to both novice and experienced users.

Installation

You can install bursty_dynamics via pip:

.. code-block:: sh

pip install bursty_dynamics

Usage

Here's a quick overview of how to use the main functionalities of the package:

.. code-block:: python

from bursty_dynamics.scores import calculate_scores
from bursty_dynamics.trains import train_detection, train_info, train_scores

# Load your longitudinal data into a DataFrame
# df = load_data()

# calculate BP and MC
score_df = calculate_scores(df, subject_id = 'eid', time_col = 'event_dt')

For more example of usage, please take a look at examples.ipynb in the example folder.

Getting Help

For more information about bursty_dynamics, please check out:

  • bursty_dynamics documentation <https://ai-multiply.github.io/bursty_dynamics/>__

License

|License|

bursty_dynamics is licensed under the MIT License. See the LICENSE file for more details.

.. |PyPI| image:: https://badge.fury.io/py/bursty-dynamics.svg :target: https://badge.fury.io/py/bursty-dynamics .. |Documentation| image:: https://img.shields.io/badge/docs-latest-blue.svg :target: https://ai-multiply.github.io/bursty_dynamics/ .. |License| image:: https://img.shields.io/badge/license-MIT-green.svg :target: https://github.com/ai-multiply/bursty_dynamics/blob/main/LICENSE.txt

Contributing

Contributions are welcome! If you encounter any issues or have suggestions for improvements, feel free to open an issue <https://github.com/ai-multiply/bursty_dynamics/issues>_ or for questions, suggestions, or general discussion related to our project, please visit our GitHub Discussions page <https://github.com/ai-multiply/bursty_dynamics/discussions>_.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

bursty_dynamics-0.1.1.tar.gz (12.2 kB view details)

Uploaded Source

Built Distribution

bursty_dynamics-0.1.1-py3-none-any.whl (13.2 kB view details)

Uploaded Python 3

File details

Details for the file bursty_dynamics-0.1.1.tar.gz.

File metadata

  • Download URL: bursty_dynamics-0.1.1.tar.gz
  • Upload date:
  • Size: 12.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.9.20

File hashes

Hashes for bursty_dynamics-0.1.1.tar.gz
Algorithm Hash digest
SHA256 e94d67bc4dfee15ec1cd5265df7fdb44c8bf3dac322daa7ef6b78bc587903296
MD5 7c5819dc4b1b2537bc76c74f7c11aa26
BLAKE2b-256 7915e6be38021bc31576150c0eb336a1a2b67f41cd558a2bb72107a2c7378606

See more details on using hashes here.

File details

Details for the file bursty_dynamics-0.1.1-py3-none-any.whl.

File metadata

File hashes

Hashes for bursty_dynamics-0.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 61f3e60108ab44bf2a6f2de0c6eb4dc5d5731f36d938d4b8a28bf7df1195a6a3
MD5 4d6c9366a143d26d76c83fe07c359d2d
BLAKE2b-256 fb9c3b5566748e639415df30c7a409bafb5e2cb4888c787d94209beee13ac9fd

See more details on using hashes here.

Supported by

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