Niceplots
A collection of styles and helper functions for making nice plots with matplotlib
Install / Use
/learn @mdolab/NiceplotsREADME
NicePlots
A collection of nice styles and helper functions for matplotlib
<img src="https://mdolab-niceplots.readthedocs-hosted.com/en/latest/_images/sphx_glr_plot_parula_contours_001.svg" width="61%" /> <img src="https://mdolab-niceplots.readthedocs-hosted.com/en/latest/_images/sphx_glr_plot_opt_prob_002.svg" width="38.2%" /> <img src="https://mdolab-niceplots.readthedocs-hosted.com/en/latest/_images/sphx_glr_plot_bar_chart_001.svg" width="61%" /> <img src="https://mdolab-niceplots.readthedocs-hosted.com/en/latest/_images/sphx_glr_plot_style_demo_004.svg" width="38.2%" />
<!-- https://mdolab-niceplots.readthedocs-hosted.com/en/latest/_images/ -->How do I install?
NicePlots can be pip installed directly from PyPI
pip install niceplots
If you want to make changes
- Clone this repository, then enter the folder in the command line terminal.
- Enter
pip install -e .within theniceplotsfolder.
Font installation
As of v2.6.0, NicePlots now comes packaged with the fonts required for its custom styles, so you don't need to install them yourself.
How do I get set up?
import matplotlib.pyplot as pltandimport niceplotsat the top of a file where you would like to use any function defined in this package.- Use
plt.style.use(niceplots.get_style())to set some defaults for nice-looking plots. You can also try passing different styles toget_style(), such as NicePlots'"james-dark"or any of matplotlib's styles (see the function's documentation for a full list of available NicePlots styles). - Take advantage of NicePlots' helper functions, including (but not limited to)
adjust_spines,horiz_bar, andplot_nested_pie, which are all documented in the examples gallery. - Admire your beautiful data.
Do you have docs?
Sort of, you can find our examples gallery and API documentation here
Help, my old NicePlots code doesn't work anymore!
We made a couple of changes to the API in version 2.0.0, most of them can be fixed with a simple find and replace. Check the release notes for more details.
Contribution guidelines
Make any changes you see fit. Please fork your own version and submit a pull request.
Who do I talk to?
Please post questions and suggestions to either the issues (if it's concerning a bug) or discussions tab on the NicePlots GitHub repo.
Related Skills
node-connect
343.1kDiagnose OpenClaw node connection and pairing failures for Android, iOS, and macOS companion apps
frontend-design
90.0kCreate distinctive, production-grade frontend interfaces with high design quality. Use this skill when the user asks to build web components, pages, or applications. Generates creative, polished code that avoids generic AI aesthetics.
openai-whisper-api
343.1kTranscribe audio via OpenAI Audio Transcriptions API (Whisper).
qqbot-media
343.1kQQBot 富媒体收发能力。使用 <qqmedia> 标签,系统根据文件扩展名自动识别类型(图片/语音/视频/文件)。
