plot_style — Publication-quality Matplotlib style¶
Matplotlib style baseline for publication-quality figures.
Usage (at the top of every paper-figure notebook):
from foregrounds_diffusion.plot_style import apply, WONG apply(fig_width_pt=246.0) # MNRAS single column apply(fig_width_pt=510.0, n_cols=2) # MNRAS double column
Save convention (always PDF primary, PNG backup):
fig.savefig(FIGURES_DIR / “fig01_cib_fullsky.pdf”) fig.savefig(FIGURES_DIR / “fig01_cib_fullsky.png”, dpi=300)
- foregrounds_diffusion.plot_style.apply(fig_width_pt=246.0, n_cols=1)[source]¶
Set rcParams for publication-quality figures.
- Parameters:
fig_width_pt – Journal text width in points. 246 pt ≈ MNRAS single column; 510 pt ≈ MNRAS double column. Pass the LaTeX textwidth value.
n_cols – Figure column span (1 or 2). Width is multiplied accordingly so
fig_width_pt=246, n_cols=2gives a figure spanning both columns.
- Return type:
list[str]- Returns:
list[str] – The WONG colour palette, for convenience (avoids a second import).
- Parameters:
fig_width_pt (float)
n_cols (int)