Skip to main content

Prepare an Input Panel

Use a long CSV with one row per geography and observed period. The inference loader requires configured date, geography, and outcome columns; treatment is defined in YAML, not read from a treatment flag in the CSV.

Required checks

  1. Use stable geography identifiers and one geographic level.
  2. Use a regular time interval appropriate to the campaign and outcome.
  3. Confirm that every intended unit-period has one finite outcome.
  4. Make the intervention date an observed period.
  5. Preserve enough observations before and after the resolved measurement start.
  6. Use a consistent outcome definition, currency, attribution window, and data production process across geographies and time.

Inference defaults to duplicate_policy: error and missing_outcome_policy: error. Alternative policies are explicit analytical decisions. mean or sum changes duplicate rows before pivoting; drop_unit, drop_period, or impute_with_report changes the estimable panel.

With impute_with_report, interpolation and endpoint filling use observations from the same pre-treatment, cooldown, or measurement window. A geography with no observed outcome in a window fails; supply data or choose an explicit drop policy. The method uses observed-period positions rather than elapsed time, so keep the observation cadence appropriate to the analysis.

Optional covariates are numeric pre-period baseline means. They use only retained outcome periods, average duplicate records within a period before averaging periods, and skip missing covariate observations. Every unit/feature needs an observed finite baseline. For direct-data runs, prepare this baseline table before passing covariates_df; GeoSC cannot infer its source dates.

data_path: data/client_panel.csv
date_col_name: date
location_col_name: region_id
outcome_col_name: revenue
date_format: "%Y-%m-%d"
treatment_unit_ids: ["FRJ"]
intervention_date_str: "2026-09-01"
duplicate_policy: error
missing_outcome_policy: error

Do not use locale-dependent date parsing in an audited run. After execution, review data_validation.json; a successful model does not supersede a failed data contract.