paper-figures

Make publication figures for a research paper with the Advay's Papers library. Covers graphs, bar charts with error bars, model-versus-baseline comparisons, ablations, learning curves, per-run plots, metric-choice figures, time series, and architecture or pipeline diagrams. Use when the user asks for a graph, plot, chart, figure, diagram, "make the figures", "fix this figure", "the text in my figure is too small", or wants figures sized for IEEE or another two-column format. NOT for dashboards, slide graphics or interactive charts.

¿Qué es paper-figures?

paper-figures is a Claude Code agent skill that make publication figures for a research paper with the Advay's Papers library. Covers graphs, bar charts with error bars, model-versus-baseline comparisons, ablations, learning curves, per-run plots, metric-choice figures, time series, and architecture or pipeline diagrams. Use when the user asks for a graph, plot, chart, figure, diagram, "make the figures", "fix this figure", "the text in my figure is too small", or wants figures sized for IEEE or another two-column format. NOT for dashboards, slide graphics or interactive charts.

Compatible con~Claude Code~Codex CLI~Cursor
npx skills add https://github.com/advaycode/advays-papers/tree/HEAD/skills/paper-figures

Installed? Explore more Investigación y análisis de datos skills: affaan-m/uspto-database, affaan-m/scholar-evaluation, affaan-m/literature-review · View all 6 →

Preguntar en tu IA favorita

Abre un nuevo chat con esta habilidad de agente ya precargada.

Vista previa

Del README del skill

Macro-AUPRC for the method and each baseline. Error bars are one SD over 12 runs. The method
exceeds every baseline; the two naive scorers mark the prevalence floor.

Documentación

Paper figures

Figures are drawn by the project's figures.py from data files, at the exact width they print at, and saved with a record of where their numbers came from.

from advays_papers.figures import charts, save

fig, ax = charts.ranked_bars(
    ["Method (ours)", "Baseline", "Random"], [0.42, 0.31, 0.10],
    errs=[0.03, 0.02, 0.004], roles=["primary", "baseline", "reference"],
    xlabel="Macro-AUPRC", floor=0.10, floor_label="floor",
    slot="column", venue="ieee_journal")
save(fig, "figures", "baselines",
     caption="Macro-AUPRC for the method and each baseline.",
     answers="Does the method beat the baselines by more than the run-to-run spread?",
     sources=["data/results.json"], command="python figures.py")

Run with python -m advays_papers figures <folder>.

Start from the reviewer's question

Every figure answers one question. Decide the question, then pick the builder.

QuestionBuilder
Does the method beat the baselines, and by how much?charts.ranked_bars
What does each ablation or condition score?charts.bars
Is the result stable across folds or datasets?charts.grouped_bars
Is the spread from the seed or from the data split?charts.run_strip
Did training converge? Is it overfitting?charts.learning_curves
Is this metric honest for this class balance?charts.metric_vs_floor
Had the simulation or signal settled before analysis?charts.timeseries
What goes where in the model or pipeline?charts.flow_diagram

For anything else, call style.figure(slot, venue=...) and draw on the axes yourself; the style, sizing and save still apply. charts.panels(n, slot="wide") gives side-by-side axes and panel_title(ax, "a", "Title") labels them (a) Title so the caption can refer to panels.

If a figure does not answer a question the text asks, cut the figure.

The rules

  1. Draw at final size. slot="column" is one text column, slot="wide" spans the page. The width comes from the venue (IEEE: 3.50 in and 7.16 in). Never draw wide and shrink into a column: a 7 in figure placed in a 3.5 in column prints every label at half size. check flags a figure whose drawn width does not match its slot.
  2. Nothing under 7 pt. save raises if any text on the figure is smaller. Shorten the label or split the figure; do not lower the limit.
  3. Colour carries a role. primary (the method), baseline, reference (chance, floor, naive scorers), accent (ablations, mean lines), positive, negative, muted. The palette is Okabe-Ito, which survives colour-blind readers and greyscale printing. Do not add colours for decoration, and do not rely on colour alone when two series could be confused: use the legend order, markers or direct labels too.
  4. Show the uncertainty. Error bars on every aggregated value, and the caption says what they are (one SD over 3 seeds, a 95% bootstrap interval, a range). For five or fewer runs per group, show the runs themselves with run_strip instead of a bar.
  5. Draw the reference level. Chance, the prevalence floor, the previous best. A bar means little without the line it should be compared against.
  6. Bars start at zero. No truncated axes on bar charts. Lines may use a tight range.
  7. No title inside a single-panel figure. The caption is the title. Panel titles are for multi-panel figures only.
  8. Print the value on bars when a reader will want the number (the builders do this).
  9. Record the source. Pass sources=[...] to save. The manifest stores a sha256 of each data file with a path relative to the figure folder, so it survives a move to another machine.
  10. Never plot numbers typed into the script. Read them from the results file the experiment wrote. A typed array is a figure that silently goes stale.

Captions

A caption lets a reader understand the figure without the text: what is plotted, what the error bars are, what n is, and the one thing to notice. End it with a full stop. In paper.md:

![Macro-AUPRC for the method and each baseline. Error bars are one SD over 12 runs. The method
exceeds every baseline; the two naive scorers mark the prevalence floor.](figures/baselines.png){#fig:baselines}

Add wide inside the braces for a figure that spans both columns, and draw it with slot="wide".

Structure and photo figures

Molecular renders, microscope images and photos are images you place, not charts you draw. Export them at 300 DPI at the slot width, add labels as real text (not baked-in screenshots), and give the viewing direction and scale in the caption. State what the image is evidence of and what it is not.

Then look at it

Open the PNG. Check: labels do not collide, the legend does not cover data, the smallest text is readable at 100% zoom, and the figure still makes sense in greyscale. Then build the paper and look at the page it lands on.

Skills relacionados