Skip to main content

GoldenViz is a Python library that analyzes matplotlib and seaborn charts and checks whether they follow data visualization best practices (the Golden Rules of Data Visualization).

Project description

GoldenViz

GoldenViz is a lightweight Python library for checking Matplotlib charts against practical data visualization rules.

It is designed as a visual QA and teaching layer. GoldenViz does not create charts for you; it inspects charts you already made and returns structured feedback.

GoldenViz is inspired by the course and book: The 25 Golden Rules of Data Viz.

Installation

pip install GoldenViz

Then import the package with the same capitalization:

import GoldenViz as gv

Quickstart

import matplotlib.pyplot as plt
import GoldenViz as gv

fig, ax = plt.subplots()
ax.plot([2021, 2022, 2023], [10, 13, 16])
ax.set_title("Revenue trend by year")
ax.set_xlabel("Year")
ax.set_ylabel("Revenue (M EUR)")

gv.check(fig)

Running the code displays the Matplotlib chart first, then a GoldenViz report. The report summarizes the checks and lists the rules that need attention:

GoldenViz report
Automatic visual QA for the 25 Golden Rules.

PASS 25 | WARNING 0 | FAIL 0

Axis: Revenue trend by year
Needs attention: none

Passing checks include:
- Clear title: PASS
- Axis labels: PASS
- Units and scale clarity: PASS

The documentation includes the rendered chart and full HTML report preview: https://goldenviz.readthedocs.io/en/latest/installation.html

Report preview:

GoldenViz report preview

To get a structured report instead of displaying it:

report = gv.analyze(fig)
print(report.summary_counts)

Notebook auto mode

import GoldenViz as gv

gv.auto()

When auto mode is enabled, GoldenViz tries to show a report after Matplotlib figures are rendered in notebook workflows.

Documentation

Full installation, usage, examples, API, citation, license, and trademark information are available in the documentation:

https://goldenviz.readthedocs.io

Project status

GoldenViz is currently an alpha package. The implementation is Matplotlib-first, with Seaborn charts supported when they produce standard Matplotlib axes.

GoldenViz uses heuristic checks. It can help detect common chart quality issues, but it does not replace human judgment and may produce false positives or false negatives.

See CHANGELOG.md for release notes.

Development

From a local checkout:

pip install -e .

For documentation work:

pip install -e ".[docs]"

For tests:

pip install -e ".[test]"
pytest

License

GoldenViz is free and open source software licensed under the GNU Affero General Public License version 3 or later (AGPL-3.0-or-later). See LICENSE.

Commercial licensing, enterprise use cases, hosted services, or integrations that require terms different from AGPLv3 may be available by separate written agreement.

GoldenViz and the GoldenViz logo are trademarks or claimed trademarks of Wajdi Ben Saad. Use of the code under AGPLv3 does not grant permission to use the GoldenViz name or logo to imply endorsement, official status, or partnership. See TRADEMARKS.md.

Contributing

Contributions are welcome. See CONTRIBUTING.md for the development workflow and contribution licensing terms.

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

goldenviz-0.1.0.tar.gz (37.3 kB view details)

Uploaded Source

Built Distribution

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

goldenviz-0.1.0-py3-none-any.whl (46.8 kB view details)

Uploaded Python 3

File details

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

File metadata

  • Download URL: goldenviz-0.1.0.tar.gz
  • Upload date:
  • Size: 37.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for goldenviz-0.1.0.tar.gz
Algorithm Hash digest
SHA256 310327b056568732186ecbfb1307c3ce07fe9964cc04686b0084f8b9c8b3ef02
MD5 8a5da08fc99b8b28e0ebb008c534cdfa
BLAKE2b-256 eed9b4bece60500a5077d0826fc3ee84c96168fba63151a493161acf69ed50fd

See more details on using hashes here.

Provenance

The following attestation bundles were made for goldenviz-0.1.0.tar.gz:

Publisher: pypi-publish.yml on WajdiBenSaad/GoldenViz

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

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

File metadata

  • Download URL: goldenviz-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 46.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for goldenviz-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 84434b3a8014bb7160088887ee84f2e968ec123ac62e58ba0c1c777bdcd6f21a
MD5 aefb09735ad7245a5a58ea356412dfd0
BLAKE2b-256 988059f749ac15b443a6ab4b57f5f9138fde4552ebdb86cf92d34b3dfbcc4609

See more details on using hashes here.

Provenance

The following attestation bundles were made for goldenviz-0.1.0-py3-none-any.whl:

Publisher: pypi-publish.yml on WajdiBenSaad/GoldenViz

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

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