tidydraws
A tidybayes-inspired data layer for declarative Bayesian visualisation in Python
tidydraws turns MCMC output (ArviZ) into tidy Polars frames that are ready to plot — one .to_pandas() away from any ggplot-like backend. It does no plotting itself. Three functions, three spaces:
| Function | Space | Plot archetype |
|---|---|---|
parameter_draws() |
parameter | density, forest, scatter |
prediction_draws() |
prediction | ribbon + line, fit + data |
compare_draws() |
comparison | prior vs posterior, intervals |
Install
With uv:
uv add tidydraws
With pip:
pip install tidydraws
If you want the latest functionality merged into main but not yet released, install directly from GitHub:
pip install git+https://github.com/drbenvincent/tidydraws.git
Or with uv:
uv add git+https://github.com/drbenvincent/tidydraws.git
Why tidydraws?
Plotting MCMC output in Python means manually slicing xarray dimensions, iterating groups, and aligning coordinates — imperative, verbose, error-prone. R's tidybayes solved this with a data layer that respects parameter space vs prediction space. tidydraws brings that to Python on Polars.
Backend-agnostic:
tidydrawsreturns PolarsDataFrames. Call.to_pandas()to bridge to lets-plot, plotnine, or any library that takes pandas. See the examples for both lets-plot and plotnine versions.
Inspired by tidybayes for R.
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
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 tidydraws-0.4.2.tar.gz.
File metadata
- Download URL: tidydraws-0.4.2.tar.gz
- Upload date:
- Size: 473.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via:
twine/6.1.0 CPython/3.13.13
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
133bacdc391fe3416b4e7fc2c4de79b0cb5be18faf655d1642de14aace7df7e9
|
|
| MD5 |
03d3cd4881c0753e19973064461b5fdb
|
|
| BLAKE2b-256 |
daa8a30b6d32ee63e84ac47ccd8f954d2d7a8854031c632ebf5b68e1ec558abc
|
Provenance
The following attestation bundles were made for tidydraws-0.4.2.tar.gz:
Publisher:
publish.yml on drbenvincent/tidydraws
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
tidydraws-0.4.2.tar.gz -
Subject digest:
133bacdc391fe3416b4e7fc2c4de79b0cb5be18faf655d1642de14aace7df7e9 - Sigstore transparency entry: 2168165859
- Sigstore integration time:
-
Permalink:
drbenvincent/tidydraws@b210198f45a95b87490284748aac69c886c5a4b4 -
Branch / Tag:
refs/tags/0.4.2 - Owner: https://github.com/drbenvincent
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@b210198f45a95b87490284748aac69c886c5a4b4 -
Trigger Event:
push
-
Statement type:
File details
Details for the file tidydraws-0.4.2-py3-none-any.whl.
File metadata
- Download URL: tidydraws-0.4.2-py3-none-any.whl
- Upload date:
- Size: 12.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via:
twine/6.1.0 CPython/3.13.13
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
4bbe76d1434778dd1d6dd4fda21a8544c5ba315189592225947ee4630c5716ae
|
|
| MD5 |
4a3ea5f3708d28cb08bb0543747db988
|
|
| BLAKE2b-256 |
6e887c1c14fc5ae7910b4e8dcd8dbb7da91711c0e0647a422c9d64f5db76ae27
|
Provenance
The following attestation bundles were made for tidydraws-0.4.2-py3-none-any.whl:
Publisher:
publish.yml on drbenvincent/tidydraws
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
tidydraws-0.4.2-py3-none-any.whl -
Subject digest:
4bbe76d1434778dd1d6dd4fda21a8544c5ba315189592225947ee4630c5716ae - Sigstore transparency entry: 2168165874
- Sigstore integration time:
-
Permalink:
drbenvincent/tidydraws@b210198f45a95b87490284748aac69c886c5a4b4 -
Branch / Tag:
refs/tags/0.4.2 - Owner: https://github.com/drbenvincent
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@b210198f45a95b87490284748aac69c886c5a4b4 -
Trigger Event:
push
-
Statement type: