Experimental data utilities: error propagation and LaTeX table generator
Project description
labdatautils
A Python library for experimental data analysis and reporting.
Includes tools for error propagation and LaTeX-ready table formatting — all with consistent significant-figure handling.
Features
- Error propagation via finite difference derivatives, with correct significant figures.
- LaTeX table generation with support for merged value ± error columns.
- Designed for clarity and reproducibility in lab reports.
Installation
pip install labdatautils
Function Reference
1. propagate(func, *args)
Arguments:
func(callable) — Function whose result and uncertainty are to be calculated.*args— Values and uncertainties, alternating:val1, err1, val2, err2, ...
Each can be a float, list, or NumPy array (all arrays must have the same length).
Returns:
values(ndarray) — Computed function results.errors(ndarray) — Propagated uncertainties.
2. generate_latex_table(column_headers, data_columns, **kwargs)
Arguments:
column_headers(list of str) — Ordered list of column names to display.data_columns(sequence of arrays) — One array per column, in the same order ascolumn_headers.
Each array should contain the values for that column.caption(str, optional) — Table caption. Default:"Data Table".label(str, optional) — LaTeX label for referencing. Default:"tab:data".error_map(dict or list of str, optional) — Maps error columns to their associated value column.
Example:{"dx": "x", "dy": "y"}or["dx:x", "dy:y"].merge_error_style(str, optional) — How to display value and error pairs:
"separate"(two columns),"pm"(e.g.1.23 ± 0.04),"paren"(e.g.1.23(4)). Default: `"separate"
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
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 lab_data_utils-0.1.0.tar.gz.
File metadata
- Download URL: lab_data_utils-0.1.0.tar.gz
- Upload date:
- Size: 8.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.12.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
cc69087c65e12b7e710e960a47973e835b63cebfd9430503f889c464cb0aad3a
|
|
| MD5 |
484dbe7f570a6e35e09fe99ed823cf80
|
|
| BLAKE2b-256 |
2d6f72fb98879c7b5574c7dec26a1193bdd4d79ec66ed234d49e233067da652d
|
Provenance
The following attestation bundles were made for lab_data_utils-0.1.0.tar.gz:
Publisher:
publish.yml on Pablo-CastroPerez/lab-data-utils
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
lab_data_utils-0.1.0.tar.gz -
Subject digest:
cc69087c65e12b7e710e960a47973e835b63cebfd9430503f889c464cb0aad3a - Sigstore transparency entry: 394674494
- Sigstore integration time:
-
Permalink:
Pablo-CastroPerez/lab-data-utils@4ae7b1d30051e06807849f7f5f5d1761f18bc850 -
Branch / Tag:
refs/tags/v0.1.0 - Owner: https://github.com/Pablo-CastroPerez
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@4ae7b1d30051e06807849f7f5f5d1761f18bc850 -
Trigger Event:
release
-
Statement type:
File details
Details for the file lab_data_utils-0.1.0-py3-none-any.whl.
File metadata
- Download URL: lab_data_utils-0.1.0-py3-none-any.whl
- Upload date:
- Size: 9.1 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.12.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
68c1b02b2e72912f620b933a9607378d75891a60e0841d7a07da158578eda599
|
|
| MD5 |
be156e6c98d23d43b1c3e001b96c69ef
|
|
| BLAKE2b-256 |
0f538f9385c4c29f834e3c869c1e301947287730486981f375c22de0483ebd19
|
Provenance
The following attestation bundles were made for lab_data_utils-0.1.0-py3-none-any.whl:
Publisher:
publish.yml on Pablo-CastroPerez/lab-data-utils
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
lab_data_utils-0.1.0-py3-none-any.whl -
Subject digest:
68c1b02b2e72912f620b933a9607378d75891a60e0841d7a07da158578eda599 - Sigstore transparency entry: 394674520
- Sigstore integration time:
-
Permalink:
Pablo-CastroPerez/lab-data-utils@4ae7b1d30051e06807849f7f5f5d1761f18bc850 -
Branch / Tag:
refs/tags/v0.1.0 - Owner: https://github.com/Pablo-CastroPerez
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@4ae7b1d30051e06807849f7f5f5d1761f18bc850 -
Trigger Event:
release
-
Statement type: