Skip to main content

Implementation of event-based models for degenerative diseases.

Project description

EBM

This is the python package for implementing Event Based Models for Disease Progression.

Installation

pip install alabEBM

Generate Random Data

from alabEBM import generate, get_params_path
import os

# Get path to default parameters
params_file = get_params_path()

# Generate data using default parameters
S_ordering = [
    'HIP-FCI', 'PCC-FCI', 'AB', 'P-Tau', 'MMSE', 'ADAS',
    'HIP-GMI', 'AVLT-Sum', 'FUS-GMI', 'FUS-FCI'
]

generate(
    S_ordering=S_ordering,
    real_theta_phi_file=params_file,  # Use default parameters
    js = [50, 100], # Number of participants
    rs = [0.1, 0.5], # Percentage of non-diseased participants
    num_of_datasets_per_combination=2,
    output_dir='my_data'
)

Run MCMC Algorithms

from alabEBM import run_ebm
from alabEBM.data import get_sample_data_path
import os

print("Current Working Directory:", os.getcwd())

for algorithm in ['soft_kmeans', 'conjugate_priors', 'hard_kmeans']:
    results = run_ebm(
        data_file=get_sample_data_path('25|50_10.csv'),  # Use the path helper
        algorithm=algorithm,
        n_iter=2000,
        n_shuffle=2,
        burn_in=1000,
        thinning=20,
    )

Features

  • Multiple MCMC algorithms:

    • Conjugate Priors
    • Hard K-means
    • Soft K-means
  • Data generation utilities

  • Extensive logging

Project details


Release history Release notifications | RSS feed

Download files

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

Source Distribution

alabEBM-0.1.1.tar.gz (4.8 kB view details)

Uploaded Source

Built Distribution

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

alabEBM-0.1.1-py3-none-any.whl (5.1 kB view details)

Uploaded Python 3

File details

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

File metadata

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

File hashes

Hashes for alabEBM-0.1.1.tar.gz
Algorithm Hash digest
SHA256 22f9ec091aa1f21a5033346df0271e9d7e9cc199095b64e48dc710baaf057e6a
MD5 dfa0a8a6ee3c9f4f027590cac5039327
BLAKE2b-256 7f088d17ab8e9c8b231e068a7ac223f6cdbdbac0674512c63354f070a937a9ce

See more details on using hashes here.

File details

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

File metadata

  • Download URL: alabEBM-0.1.1-py3-none-any.whl
  • Upload date:
  • Size: 5.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.8.19

File hashes

Hashes for alabEBM-0.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 bcdd7823d5d02eca37dd7309b37678bc5f61444ea33452a49e9fe62bddc5d9ac
MD5 2da7a21f97378f64fbfd3dc7fba5080a
BLAKE2b-256 5cf96aa02846f47df22faf608f37d911184fcbf517b671109cc236e0c5844d51

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