Extract matplotlib plots components
Project description
matplotlib-extract
This package is useful to create dynamic presentations where elements of a plot appear one by one. To do so, the elements are exported to seperate files.
Install with
pip install matplotlib-extract
Usage
import matplotlib.pyplot as plt
from matplotlib_extract import extract_elements
import numpy as np
x = np.linspace(0, 2*np.pi)
y1 = 2*x
y2 = 6 + 2*np.sin(x)
plt.plot(x, y1, label="line1")
plt.plot(x, y2, label="line2")
plt.legend()
extract_elements()
plt.show()
Running this script will create files for the lines, the axis and the legend.
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
matplotlib_extract-0.1.tar.gz
(8.4 kB
view hashes)
Built Distribution
Close
Hashes for matplotlib_extract-0.1-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 82a71e563524c10377d010d3334f76c9f30b61c3dd517fa44f25b5ab2bc1cef5 |
|
MD5 | 7260afe7bd28327ed69ebaa11cc0ea5d |
|
BLAKE2b-256 | c0e68ec5587298b892ddfaf5f509c67c2ba39d775c435f890c82bfb3999fda22 |