Skip to content

tausurv.plot.style

Named plotting styles for tausurv.

Four styles, opt-in:

  • publication — single-column journal default. Compact, restrained.
  • presentation — slides and posters. Larger fonts, thicker lines.
  • notebook — interactive analysis. Matplotlib defaults plus the Okabe-Ito palette and minor spine/grid cleanup.
  • minimal — spineless, gridless. For embedding in mixed-media reports where surrounding context provides axes.

Apply with set_style(name) for a session-wide change or style_context(name) as a scoped context manager. Both accept a palette name override.

set_style(name: StyleName = 'publication', palette: PaletteName = 'okabe_ito', **overrides) -> None

Apply a named tausurv style globally.

  • name — minimal — Style preset.
  • palette — tol_muted — Categorical palette driving axes.prop_cycle.
  • **overrides — Additional rcParam keys, applied last.

Mutates matplotlib.rcParams for the active session. Use style_context for a scoped alternative.

style_context(name: StyleName = 'publication', palette: PaletteName = 'okabe_ito', **overrides) -> AbstractContextManager[None]

Return a context manager scoping a tausurv style to a with block.

  • name — minimal
  • palette — tol_muted
  • **overrides — Additional rcParam keys, applied last.

with ts.plot.style_context(“presentation”): … fig, ax = plt.subplots() … ax.plot(t, S)