Skip to main content

Lightweight Bland–Altman plot implementation for method comparison

Project description

Bland-Altman Plot

A lightweight Python library for generating Bland-Altman Plots to evaluate agreement between two measurements methods. This implementation provides a simple interface for quickly visualizing bias and limits of agreements.

Installation

Install from PyPI

pip install bland-altman

Usage

import numpy as np
from bland_altman import bland_altman_plot

# Generate example data
np.random.seed(42) 
x = np.random.normal(100,10,500)
y = x + np.random.normal(0,5,500)

# Generate Bland-Altman plot
bland_altman_plot(x, y, ylim=(-20, 20), figsize=(10,6), label_offset=0.025, color='blue', alpha=0.5, display_grid=True, display_legend=True)

Example Plot

Below is an example Bland-Altman plot generated using this library.


Features

  • Simple and easy-to-use API
  • Automate calculation of mean difference and limits of agreement
  • Customizable plot appearance
  • Buit using Numpy and Matplotlib

Requirements

  • Python 3.8+
  • NumPy
  • Matplotlib

These dependencies will be installed automatically with the package.


License

This project is licensed under MIT License.

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

bland_altman-0.1.4.tar.gz (5.4 kB view details)

Uploaded Source

Built Distribution

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

bland_altman-0.1.4-py3-none-any.whl (5.3 kB view details)

Uploaded Python 3

File details

Details for the file bland_altman-0.1.4.tar.gz.

File metadata

  • Download URL: bland_altman-0.1.4.tar.gz
  • Upload date:
  • Size: 5.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.11.5

File hashes

Hashes for bland_altman-0.1.4.tar.gz
Algorithm Hash digest
SHA256 f7bba7a4a30b2187910fb63853cd8ce1cbc5d96fdc6c8bc7b39e77c727f8a3d2
MD5 56eac66533d74ce942f49972a9b7d86e
BLAKE2b-256 e219dd58274396f25902f7a959eee2e6158dbf2c37759cbb87e6a0b9dba2ecb9

See more details on using hashes here.

File details

Details for the file bland_altman-0.1.4-py3-none-any.whl.

File metadata

  • Download URL: bland_altman-0.1.4-py3-none-any.whl
  • Upload date:
  • Size: 5.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.11.5

File hashes

Hashes for bland_altman-0.1.4-py3-none-any.whl
Algorithm Hash digest
SHA256 51655330cf78a896b1ff630ab0b072d2673b66fbd9040924c6c5b6ca663ab606
MD5 f258ed27f8e2f37ce1ac3f5515c2d5e3
BLAKE2b-256 817bf3c0195d7622ce07befd1c577dcf7dd70751e6926d3897f977c9a4679d29

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