diff_diff.SunAbrahamResults#
- class diff_diff.SunAbrahamResults[source]#
Bases:
objectResults from Sun-Abraham (2021) interaction-weighted estimation.
- event_study_effects#
Dictionary mapping relative time to effect dictionaries with keys: ‘effect’, ‘se’, ‘t_stat’, ‘p_value’, ‘conf_int’, ‘n_groups’.
- Type:
- overall_att#
Overall average treatment effect (weighted average of post-treatment effects).
- Type:
- vcov_type#
Variance-covariance family from the fit-time configuration (
classical,hc1,hc2,hc2_bm, orconley). On the"conley"(spatial-HAC) path,conley_lag_cutoffandcluster_nameare populated. Note: when asurvey_design=is supplied, the survey-design Taylor Series Linearization (or replicate-weight refit) variance overrides this analytical family — the field still records the configured value butsurvey_metadataindicates the survey path was active. Likewise, on bootstrap fits (n_bootstrap > 0) the SE comes from the pairs bootstrap (or Rao-Wu rescaled bootstrap under stratified / PSU survey designs), not the analytical family.- Type:
Methods
__init__(event_study_effects, overall_att, ...)print_summary([alpha])Print summary to stdout.
summary([alpha])Generate formatted summary of estimation results.
to_dataframe([level])Convert results to DataFrame.
Attributes
anticipationattbootstrap_resultscluster_namecoef_varSE / abs(overall ATT).
cohort_effectsconf_intconley_lag_cutoffevent_study_vcovevent_study_vcov_indexis_significantCheck if overall ATT is significant.
p_valuesesignificance_starsSignificance stars for overall ATT.
survey_metadatat_stat- __init__(event_study_effects, overall_att, overall_se, overall_t_stat, overall_p_value, overall_conf_int, cohort_weights, groups, time_periods, n_obs, n_treated_units, n_control_units, alpha=0.05, control_group='never_treated', vcov_type='hc1', anticipation=0, bootstrap_results=None, cohort_effects=None, survey_metadata=None, event_study_vcov=None, event_study_vcov_index=None, conley_lag_cutoff=None, cluster_name=None)#
- Parameters:
overall_att (float)
overall_se (float)
overall_t_stat (float)
overall_p_value (float)
n_obs (int)
n_treated_units (int)
n_control_units (int)
alpha (float)
control_group (str)
vcov_type (str)
anticipation (int)
bootstrap_results (SABootstrapResults | None)
cohort_effects (Dict[Tuple[Any, int], Dict[str, Any]] | None)
survey_metadata (Any | None)
event_study_vcov (ndarray | None)
event_study_vcov_index (list | None)
conley_lag_cutoff (int | None)
cluster_name (str | None)
- Return type:
None
- classmethod __new__(*args, **kwargs)#