Skip to main content

Publication-ready matplotlib styles and figure helpers by SciDraw AI — colorblind-safe palettes, journal figure sizes, and panel labels for Nature, Science, Cell, PLOS, and ACS.

Project description

scidraw-ai

Publication-ready matplotlib styles and figure helpers, maintained by SciDraw AI — the AI scientific illustration and data visualization platform.

The color cycles and journal specs in this package are the same ones used by the SciDraw AI chart tools, so Python code exported from the platform reproduces identically on your machine.

Install

pip install scidraw-ai

Quick start

import matplotlib.pyplot as plt
import scidraw_ai  # registers the styles

plt.style.use('scidraw')                      # publication (light)
plt.style.use('scidraw-dark')                 # slides & screens
plt.style.use(['scidraw', 'scidraw-poster'])  # posters & talks

The scidraw style gives you:

  • Okabe-Ito colorblind-safe color cycle — the standard recommended for scientific publishing (pair the yellow with distinct markers on white backgrounds)
  • Clean axes: no top/right spines, outward ticks, frameless legends
  • Journal-friendly type sizes (7–9 pt) with Arial/Helvetica preferred
  • 300 DPI tight-bbox saving out of the box
  • Editable text in exportspdf.fonttype 42 / svg.fonttype none, so labels stay editable in Illustrator, Inkscape, or PowerPoint

Journal figure sizes

Widths follow each journal's author guidelines (Nature, Science, Cell, PLOS, ACS):

fig, ax = plt.subplots(figsize=scidraw_ai.figsize('nature', 'single'))
fig, ax = plt.subplots(figsize=scidraw_ai.figsize('science', 'double'))

Panel labels

Each journal formats panel labels differently — Nature wants bold lowercase a, Science wants (A), PLOS wants A.:

fig, axs = plt.subplots(1, 3)
scidraw_ai.label_panels(axs, journal='nature')

Palettes

Four colorblind-safe palettes, identical to the SciDraw AI platform:

scidraw_ai.set_palette('okabe-ito')   # default
scidraw_ai.set_palette('wong')
scidraw_ai.set_palette('tol-bright')
scidraw_ai.set_palette('tol-muted')

Generate figures from data, no code

Prefer not to write plotting code at all? SciDraw AI turns CSV/Excel data into journal-quality charts — box plots, heatmaps, regression and violin plots — and exports editable SVG/PDF plus the matplotlib code to reproduce them:

License

MIT

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

scidraw_ai-0.1.0.tar.gz (5.2 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

scidraw_ai-0.1.0-py3-none-any.whl (7.4 kB view details)

Uploaded Python 3

File details

Details for the file scidraw_ai-0.1.0.tar.gz.

File metadata

  • Download URL: scidraw_ai-0.1.0.tar.gz
  • Upload date:
  • Size: 5.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.9.6

File hashes

Hashes for scidraw_ai-0.1.0.tar.gz
Algorithm Hash digest
SHA256 fc31ed1d30352acaafff083633a80b8e172a3a7c10e89b38c63315ba56e2acb5
MD5 94b6f94d4f667c22ca7dd3fa4a9f34e8
BLAKE2b-256 3f1cd9cb56f39d18fc45ccf43cf8d9a1568c1b3da7ea8f1f628501262aaad3e9

See more details on using hashes here.

File details

Details for the file scidraw_ai-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: scidraw_ai-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 7.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.9.6

File hashes

Hashes for scidraw_ai-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 0a898be2640ba4e2d141dfe629ddd7e1752e7e0a973fafea267ef1ba0e057662
MD5 e13c5f8f83d913308f64c6011d8fee79
BLAKE2b-256 2aed9e9a30037c0b14882df8ab5f56bf343affb711040cd81ec05c57020ad765

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page