ReporTree produces nested static HTML reports with buttons to navigate through many matplotlib plots.
Project description
ReporTree: Nested HTML reports for Matplotlib
ReporTree produces nested static HTML reports with buttons to navigate through many matplotlib plots. The package can easily produce reports with many nested levels and hundreds of Matplotlib plots.
Basic example
import reportree as rt
import seaborn as sns
import matplotlib.pyplot as plt
import numpy as np
fig1, ax1 = plt.subplots()
sns.lineplot(x=np.arange(10), y=np.arange(10), marker='o', ax=ax1, color='red')
ax1.set_title('Upward')
fig2, ax2 = plt.subplots()
sns.lineplot(x=np.arange(10), y=np.arange(10, 0, -1), marker='o', ax=ax2, color='blue')
ax2.set_title('Downward')
l1 = rt.Leaf([fig1, fig2], title='Leaf example')
l1.save('/tmp/example1')
l2 = rt.Leaf(fig1, title='Only upward')
l3 = rt.Leaf(fig2, title='Only downward')
b1 = rt.Branch([l1, l2, l3], title='Branch example')
b1.save('/tmp/example2')
b2 = rt.Branch([rt.Branch([b1, l1]), l2, l3, b1], title='Nested example')
b2.save('/tmp/example3')
The code produces following reports:
Leaf example
Branch example
Nested example
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
reportree-0.0.4.tar.gz
(111.3 kB
view hashes)
Built Distribution
Close
Hashes for reportree-0.0.4-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | dcf58dd69efd68c2447379ad220f7bf590e8ecbb35e4de70e43d632291bc73a9 |
|
MD5 | 8b3a457e1fe0e4b8e17ac05289f9874c |
|
BLAKE2b-256 | 4de3292cbf2afac00a13031d63d7aa8c8dd75a15a057deb47876a623122bbef5 |