InterruptedTimeSeries.effect_summary#

InterruptedTimeSeries.effect_summary(*, window='post', direction='increase', alpha=0.05, cumulative=True, relative=True, min_effect=None, treated_unit=None, period=None, prefix='Post-period', **kwargs)[source]#

Generate a decision-ready summary of causal effects for Interrupted Time Series.

Parameters:
  • window (Union[Literal['post'], tuple, slice]) – Time window for analysis: - “post”: All post-treatment time points (default) - (start, end): Tuple of start and end times (handles both datetime and integer indices) - slice: Python slice object for integer indices

  • direction (Literal['increase', 'decrease', 'two-sided']) – Direction for tail probability calculation (PyMC only, ignored for OLS).

  • alpha (float) – Significance level for HDI/CI intervals (1-alpha confidence level).

  • cumulative (bool) – Whether to include cumulative effect statistics.

  • relative (bool) – Whether to include relative effect statistics (% change vs counterfactual).

  • min_effect (float | None) – Region of Practical Equivalence (ROPE) threshold (PyMC only, ignored for OLS).

  • treated_unit (str | None) – Ignored for Interrupted Time Series (single unit).

  • period (Optional[Literal['intervention', 'post', 'comparison']]) – For three-period designs (with treatment_end_time), specify which period to summarize. Defaults to None for standard behavior.

  • prefix (str) – Prefix for prose generation (e.g., “During intervention”, “Post-intervention”). Defaults to “Post-period”.

  • kwargs (Any)

Returns:

Object with .table (DataFrame) and .text (str) attributes. The .text attribute contains a detailed multi-paragraph narrative report.

Return type:

EffectSummary