Make matplotlib figures with the coorect scale.
Project description
Scale your matplotlib figures
Publication quality figures start here
Usage
import matplotlib.pyplot as plt
import figure_scale as fs
figsize = fs.FigureScale(4.0, 2.0, units="in")
plt.rcParams.update({'figure.figsize' : figsize})
fig, ax = plt.subplots(figsize=figsize)
with figsize():
fig, ax = plt.subplots()
@figsize()
def my_plot():
...
Installation
pip install figure-scale
How to Contribute
-
Fork this project, clone your repository and make it your working directory.
-
To install the project, its development dependencies, and the pre-commit hooks, just run:
poetry install poetry shell
-
The regular maintenance tasks are handled by taskipy. You can see the available tasks by running:
$ task --list pre_commit_install pre-commit install test pytest pre_lint task pre_commit_install lint pre-commit run --all-files qa task lint && task test pre_docs poetry install --with docs docs jupyter-book build docs --path-output build pre_docs_serve task pre_docs docs_serve sphinx-autobuild docs build/_build/html
Type
task <task_name>
to run a task. For example, to run the tests, trytask qa
.
Copyright and License
© 2023 Felipe N. Schuch. All content is under MIT License.
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
figure_scale-0.1.0b1.tar.gz
(5.0 kB
view details)
Built Distribution
File details
Details for the file figure_scale-0.1.0b1.tar.gz
.
File metadata
- Download URL: figure_scale-0.1.0b1.tar.gz
- Upload date:
- Size: 5.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.6.1 CPython/3.11.4 Linux/5.15.0-1041-azure
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 3298f10220e10f67e64bcb644bf2ce83a6f36333e76136deeb4e79c32ad8d677 |
|
MD5 | 81f6f06a8ed3b170ca8fa97dcaf6d2a8 |
|
BLAKE2b-256 | 62ca6b390d57fdd72a390db5ce6e1163164a67269836d3334f0d501ca3c235fd |
File details
Details for the file figure_scale-0.1.0b1-py3-none-any.whl
.
File metadata
- Download URL: figure_scale-0.1.0b1-py3-none-any.whl
- Upload date:
- Size: 5.5 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.6.1 CPython/3.11.4 Linux/5.15.0-1041-azure
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 5c2613699052024fa5b48d7948a1dcdb5a7f34d61fa95e9b8892a4f49c63964b |
|
MD5 | b3a4120b54ef9504b4b44bfe2ee38ba5 |
|
BLAKE2b-256 | 127cf74d44ec2a860bdb2a4358d6c066342446fdb10319a63c6cd3992be8ccbd |