SyntheticControl.get_plot_data#

SyntheticControl.get_plot_data(*, hdi_prob=0.94, treated_unit=None)[source]#

Recover the data of the experiment along with the prediction and causal impact information.

HDI columns are included only when the prediction container carries posterior draws (point-estimate backends return just prediction and impact).

Parameters:
  • hdi_prob (float) – Probability mass of the highest density interval. Defaults to the project-wide HDI_PROB. Ignored when the prediction container has no posterior draws.

  • treated_unit (str | None) – Which treated unit to extract data for. Must be a string name of the treated unit. If None, uses the first treated unit.

Return type:

DataFrame