probly.plot.config.PlotConfig

class probly.plot.config.PlotConfig(categorical_palette: tuple[str, ...] = ('#1e88e5', '#ff0d57', '#2ecc71', '#f39c12', '#9b59b6', '#16a085', '#d35400'), color_positive: str = '#ff0d57', color_negative: str = '#1e88e5', color_neutral: str = '#7f8c8d', color_gridline: str = '#e8e8e8', figure_size: tuple[float, float] = (6.0, 6.0), dpi: int = 100, title_fontsize: float = 14.0, label_fontsize: float = 12.0, line_width: float = 1.5, fill_alpha: float = 0.3, marker_size: float = 30.0, grid_alpha: float = 0.5, grid_linestyle: str = '--', histogram_alpha: float = 0.6, spider_bar_width: float = 0.05)[source]

Bases: object

Shared configuration for plotting functions.

Plot functions should accept config: PlotConfig | None = None and fall back to PlotConfig() when no config is provided.

categorical_palette: tuple[str, ...]
color(index: int) str[source]

Return a color from the categorical palette.

Parameters:

index – Index to select color from the palette. Will wrap around if index exceeds palette length.

Returns:

A hex color string from the categorical palette.

color_gridline: str
color_negative: str
color_neutral: str
color_positive: str
dpi: int
figure_size: tuple[float, float]
fill_alpha: float
grid_alpha: float
grid_linestyle: str
histogram_alpha: float
label_fontsize: float
line_width: float
marker_size: float
spider_bar_width: float
title_fontsize: float