# has2k1/plotnine

A Grammar of Graphics for Python

Repository: https://github.com/has2k1/plotnine
Canonical: https://ross.abutalabs.com/products/plotnine
Homepage: https://plotnine.org
Language: Python
License: MIT
License Family: permissive
Topics: plotting, grammar, graphics, python, data-analysis
Last push: 2026-08-15T12:04:49+00:00

## Health v2 (maintenance only)
Score: 98/100 (v2, computed 2026-09-03T02:20:16.233290+00:00)
- activity 97, release rhythm 98, longevity 100
- inputs: {"age_days": 3418, "days_push": 18, "days_rel": 19, "gap_med": 20, "n_releases_24m": 16}
- flags: none
- formula: round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10)

## Adoption (not part of the score)
Stars 4757, forks 253 (observed 2026-08-28T04:08:58.970194+00:00)

## What it is
plotnine is a Python data visualization library implementing the grammar of graphics, based on R's ggplot2. Plots are composed declaratively by mapping dataframe columns to visual properties, with layers, facets, scales, and themes.

## Use cases
- create scatter plots and statistical graphics in python
- ggplot2-style plotting in python
- build publication-ready figures from pandas dataframes
- facet plots across multiple panels without loops
- incrementally compose complex visualizations
- exploratory data analysis plotting

## When to choose
- you know ggplot2 and want the same grammar in Python
- you want declarative, layered plots built from pandas dataframes
- you need faceting, automatic legends, and sensible defaults for statistical graphics

## When to avoid
- you need interactive or web-based dashboards rather than static figures
- you prefer matplotlib's imperative API or need pixel-level control
- you need plot types not covered by the grammar and don't want to extend it

## Facets
- artifact type: library
- maturity: active
- function: data-visualization, charts
- domain: data-visualization, data-science
- platform: python, cross-platform
- tags: ggplot2, grammar-of-graphics, plotting, matplotlib, jupyter, statistical-graphics

## Member repositories
- has2k1/plotnine (main) score 98

## Provenance
- Observed fields: from GitHub, fetched 2026-08-28T04:08:58.970194+00:00.
- Health v2: computed from the inputs above; adoption is never an input.
- Inferred fields (summary, facets, guidance): AI-extracted, prompt v1, taxonomy v1, on 2026-08-29T18:18:52.512387+00:00, confidence not recorded.
  - readme: https://github.com/has2k1/plotnine (fetched 2026-08-28T04:08:58.970194+00:00, sha b3a3367d8704)
  - homepage: https://plotnine.org (fetched 2026-08-29T09:02:20.928244+00:00, sha 733eabd37853)
  - site_page: https://plotnine.org/guide/install.html (fetched 2026-08-29T09:02:20.935530+00:00, sha a55d082995a3)
  - registry_pypi: https://pypi.org/pypi/plotnine/json (fetched 2026-08-29T09:02:20.937225+00:00, sha 28d07f7d5a60)
  - site_page: https://plotnine.org/changelog.html (fetched 2026-08-29T09:02:20.932459+00:00, sha 8af972a07b03)
- Data as of 2026-08-30T08:39:29.467469+00:00.
