EventStudy.plot#

EventStudy.plot(*, round_to=2, hdi_prob=0.94, figsize=(10, 6), show=True, legend_kwargs=None)[source]#

Plot event-study dynamic treatment effects.

Parameters:
  • round_to (int | None) – Number of decimals for rounding coefficient labels. Defaults to 2.

  • hdi_prob (float) – Probability mass of the highest density interval for Bayesian error bars. Ignored for OLS models. Defaults to HDI_PROB.

  • figsize (tuple[float, float]) – Width and height of the figure in inches. Defaults to (10, 6).

  • show (bool) – Whether to automatically display the plot. Defaults to True.

  • legend_kwargs (dict[str, Any] | None) – Keyword arguments to adjust legend placement and styling. Supported keys: loc, bbox_to_anchor, fontsize, frameon, title.

Returns:

  • fig (matplotlib.figure.Figure) – The figure that was created.

  • ax (matplotlib.axes.Axes) – The axes object containing the plot.

Return type:

tuple[Figure, Axes]