CGPT Data Viz Auditor
Use this skill to review figures that already exist as code or rendered artifacts. The goal is a concrete audit with specific fixes, not a general design critique.
Scope
Audit:
- ggplot2, matplotlib, seaborn, base R, and static exported figures.
- Manuscript figures, tables-as-figures, multi-panel plots, diagrams, and maps.
- Accessibility and color reliability, including color vision deficiency and contrast.
- Journal readiness for marketing, management, social science, and policy-style submissions.
- UW-branded charts when the project calls for UW styling.
Do not use this skill to invent new statistical analyses. If the final artifact is DOCX, PPTX, PDF, HTML, or a rendered report, hand off final structural/output validation to cgpt-render-check.
Audit Workflow
- Identify target venue, medium, and final size when known: journal, slide, report, web, single-column, double-column, print, or screen.
- Inspect the source code and/or rendered image.
- Check labels, accessibility, color, layout, journal/export requirements, and figure numbering/captions.
- Provide PASS/WARN/FAIL with prioritized issues and exact code or artifact fixes.
- If code was changed, render the figure again when feasible.
- Run or recommend
cgpt-render-check on the final containing artifact.
Core Checklist
Labels And Text
- Axis titles are present and include units or scale transformations.
- Tick labels are readable at final size and do not overlap.
- Legends have descriptive titles and human-readable entries.
- Panel labels are consistent and referenced correctly in the caption.
- Captions belong in the manuscript or report unless the target format requires embedded text.
- Minimum print readability: 8 pt for minor labels, 10 pt or larger for axis titles and legends.
Color And Accessibility
- Palette is colorblind-safe; prefer viridis, Okabe-Ito, or vetted Brewer palettes.
- Color is not the only encoding for categories; add shape, linetype, direct labels, pattern, or faceting.
- Data marks, labels, and map boundaries have sufficient contrast against the background.
- Avoid rainbow/jet palettes, red-green-only comparisons, and default hue scales for many groups.
- For UW work, follow
uw-accessibility: exact UW colors, Spirit Gold decorative only, and no color-only meaning.
Layout And Interpretation
- Plot has a clear visual hierarchy and enough margins; labels are not clipped.
- Aspect ratio is appropriate for the venue.
- Gridlines are lighter than data marks.
- Multi-panel figures use consistent scales, labels, themes, and legend treatment unless differences are intentional.
- Direct labels are preferred when they reduce legend lookup.
- The figure supports one clear takeaway; remove decoration that competes with data.
Journal And Export Standards
- Export is at least 300 DPI for print; use 600 DPI for line art when required.
- Vector PDF/SVG/EPS is preferred for line charts and diagrams when accepted.
- Raster PNG/TIFF dimensions match target column width and file-size limits.
- Fonts are embedded or standard enough for the submission pipeline.
- Figure numbering, captions, and in-text references match the manuscript.
- Do not rely on low-resolution screenshots for submission graphics.
Maps And Spatial Figures
- Include a legend, scale bar or clear scale context, projection/CRS when relevant, and data source note.
- Choropleth bins are meaningful, labeled, and not misleading.
- Missing data is explicitly encoded and labeled.
- Avoid map projections or color ramps that distort the intended comparison.
- Boundary lines, labels, and overlays remain legible at final size.
Common Fixes
For ggplot2:
scale_color_viridis_d(option = "D")
scale_fill_viridis_d(option = "D")
labs(x = "Year", y = "Revenue (USD millions)", color = "Segment")
theme_minimal(base_size = 11) +
theme(panel.grid.minor = element_blank(),
legend.position = "bottom")
ggsave("figure-1.tiff", width = 7, height = 5, dpi = 300, compression = "lzw")
For matplotlib:
import matplotlib as mpl
mpl.rcParams.update({
"font.size": 11,
"axes.labelsize": 11,
"xtick.labelsize": 9,
"ytick.labelsize": 9,
"legend.fontsize": 9,
})
fig.savefig("figure-1.pdf", bbox_inches="tight")
fig.savefig("figure-1.png", dpi=300, bbox_inches="tight")
Report Format
Use a compact result:
Status: PASS/WARN/FAIL
Figure(s): path or identifier
Critical issues: count and short list
Recommended fixes: exact changes
Verification: rendered/inspected, plus final cgpt-render-check status or handoff
Rules
- Ground findings in visible evidence or source code.
- Separate accessibility failures from style preferences.
- Do not silently change the statistical meaning of a plot.
- When a chart is embedded in a larger deliverable, finish with
cgpt-render-check on that deliverable.
1---2name: cgpt-data-viz-auditor3description: Audit statistical figures, charts, maps, and plotting code for accessibility, labels, color, export quality, and academic journal readiness. Use when reviewing ggplot2, matplotlib, rendered figures, manuscript graphics, maps, or multi-figure submissions before delivery or journal submission.4---56# CGPT Data Viz Auditor78Use this skill to review figures that already exist as code or rendered artifacts. The goal is a concrete audit with specific fixes, not a general design critique.910## Scope1112Audit:1314- ggplot2, matplotlib, seaborn, base R, and static exported figures.15- Manuscript figures, tables-as-figures, multi-panel plots, diagrams, and maps.16- Accessibility and color reliability, including color vision deficiency and contrast.17- Journal readiness for marketing, management, social science, and policy-style submissions.18- UW-branded charts when the project calls for UW styling.1920Do not use this skill to invent new statistical analyses. If the final artifact is DOCX, PPTX, PDF, HTML, or a rendered report, hand off final structural/output validation to `cgpt-render-check`.2122## Audit Workflow23241. Identify target venue, medium, and final size when known: journal, slide, report, web, single-column, double-column, print, or screen.252. Inspect the source code and/or rendered image.263. Check labels, accessibility, color, layout, journal/export requirements, and figure numbering/captions.274. Provide PASS/WARN/FAIL with prioritized issues and exact code or artifact fixes.285. If code was changed, render the figure again when feasible.296. Run or recommend `cgpt-render-check` on the final containing artifact.3031## Core Checklist3233### Labels And Text3435- Axis titles are present and include units or scale transformations.36- Tick labels are readable at final size and do not overlap.37- Legends have descriptive titles and human-readable entries.38- Panel labels are consistent and referenced correctly in the caption.39- Captions belong in the manuscript or report unless the target format requires embedded text.40- Minimum print readability: 8 pt for minor labels, 10 pt or larger for axis titles and legends.4142### Color And Accessibility4344- Palette is colorblind-safe; prefer viridis, Okabe-Ito, or vetted Brewer palettes.45- Color is not the only encoding for categories; add shape, linetype, direct labels, pattern, or faceting.46- Data marks, labels, and map boundaries have sufficient contrast against the background.47- Avoid rainbow/jet palettes, red-green-only comparisons, and default hue scales for many groups.48- For UW work, follow `uw-accessibility`: exact UW colors, Spirit Gold decorative only, and no color-only meaning.4950### Layout And Interpretation5152- Plot has a clear visual hierarchy and enough margins; labels are not clipped.53- Aspect ratio is appropriate for the venue.54- Gridlines are lighter than data marks.55- Multi-panel figures use consistent scales, labels, themes, and legend treatment unless differences are intentional.56- Direct labels are preferred when they reduce legend lookup.57- The figure supports one clear takeaway; remove decoration that competes with data.5859### Journal And Export Standards6061- Export is at least 300 DPI for print; use 600 DPI for line art when required.62- Vector PDF/SVG/EPS is preferred for line charts and diagrams when accepted.63- Raster PNG/TIFF dimensions match target column width and file-size limits.64- Fonts are embedded or standard enough for the submission pipeline.65- Figure numbering, captions, and in-text references match the manuscript.66- Do not rely on low-resolution screenshots for submission graphics.6768### Maps And Spatial Figures6970- Include a legend, scale bar or clear scale context, projection/CRS when relevant, and data source note.71- Choropleth bins are meaningful, labeled, and not misleading.72- Missing data is explicitly encoded and labeled.73- Avoid map projections or color ramps that distort the intended comparison.74- Boundary lines, labels, and overlays remain legible at final size.7576## Common Fixes7778For ggplot2:7980```r81scale_color_viridis_d(option = "D")82scale_fill_viridis_d(option = "D")83labs(x = "Year", y = "Revenue (USD millions)", color = "Segment")84theme_minimal(base_size = 11) +85 theme(panel.grid.minor = element_blank(),86 legend.position = "bottom")87ggsave("figure-1.tiff", width = 7, height = 5, dpi = 300, compression = "lzw")88```8990For matplotlib:9192```python93import matplotlib as mpl9495mpl.rcParams.update({96 "font.size": 11,97 "axes.labelsize": 11,98 "xtick.labelsize": 9,99 "ytick.labelsize": 9,100 "legend.fontsize": 9,101})102fig.savefig("figure-1.pdf", bbox_inches="tight")103fig.savefig("figure-1.png", dpi=300, bbox_inches="tight")104```105106## Report Format107108Use a compact result:109110```text111Status: PASS/WARN/FAIL112Figure(s): path or identifier113Critical issues: count and short list114Recommended fixes: exact changes115Verification: rendered/inspected, plus final cgpt-render-check status or handoff116```117118## Rules119120- Ground findings in visible evidence or source code.121- Separate accessibility failures from style preferences.122- Do not silently change the statistical meaning of a plot.123- When a chart is embedded in a larger deliverable, finish with `cgpt-render-check` on that deliverable.