TBOX is a small Python utility library for scientific plotting and basic statistics. It currently provides helpers for Matplotlib styling, custom legends, gradients, colored arrows, and RMSE computation.
From a local checkout:
python -m pip install .For development:
python -m pip install -e ".[dev,examples]"import matplotlib.pyplot as plt
import numpy as np
from tbox import compute_rmse, rainbowarrow, set_plt
set_plt(font_size=12)
y_ref = np.array([1.0, 2.0, 3.0])
y = np.array([1.1, 2.2, 2.8])
print(compute_rmse(y, y_ref))
fig, ax = plt.subplots()
rainbowarrow(ax, start=(0, 0), end=(1, 1), cmap=("tab:blue", "tab:orange"))
plt.show()tbox.stat_basics: statistical helper functions.tbox.plot_utils: Matplotlib styling and plotting utilities.examples/: notebooks showing selected plotting helpers.
Useful checks before publishing changes:
python -m pip install -e ".[dev]"
python -m pytest
python -m compileall tbox
python -m buildThis project is distributed under the MIT License. See LICENSE.