Replication package 158611 · dataverse · 2026 · open the deposit

How the code gets from data to results

Replication Data for: Building Infrastructure and Cohesion through Locally Embedded Institutions: Evidence from a Field Experiment in War-torn Eastern Congo*

Code for: Building infrastructure and cohesion through locally embedded institutions: Evidence from a field experiment in War-torn Eastern Congo Journal of Development Economics 2027

25
scripts
11
input files
10
file hand-offs
10
merges
78
sample steps
14
estimations

1 · Data in — files the code reads and no script of the package writes

Other input files 11 files
  • $data_base/EA_CH.dta Stata
    build_pkg_datasets.do:155
    7_datawork/02. Dofiles/build_pkg_datasets.do, line 155 merge m:1 q4_cddid using "$data_base/EA_CH.dta", force
  • $data_base/EA_HH.dta Stata
    build_pkg_datasets.do:153
    7_datawork/02. Dofiles/build_pkg_datasets.do, line 153 use "$data_base/EA_HH.dta", clear
  • $data_base/EP_CH.dta Stata
    build_pkg_datasets.do:168
    7_datawork/02. Dofiles/build_pkg_datasets.do, line 168 merge m:1 q4_cddid using "$data_base/EP_CH.dta", force
  • $data_base/EP_HH.dta Stata
    build_pkg_datasets.do:166
    7_datawork/02. Dofiles/build_pkg_datasets.do, line 166 use "$data_base/EP_HH.dta", clear
  • $data_base/OSM_DRC_STEP_CDD_highway_highway_5km.dta Stata
    build_pkg_datasets.do:785
    7_datawork/02. Dofiles/build_pkg_datasets.do, line 785 use "$data_base/OSM_DRC_STEP_CDD_highway_highway_5km.dta", clear
  • $data_base/vills_DRC_STEP_CDD_climate.dta Stata
    build_pkg_datasets.do:775
    7_datawork/02. Dofiles/build_pkg_datasets.do, line 775 use "$data_base/vills_DRC_STEP_CDD_climate.dta", clear
  • $data_base/vills_DRC_STEP_CDD_ruggedness.dta Stata
    build_pkg_datasets.do:780
    7_datawork/02. Dofiles/build_pkg_datasets.do, line 780 use "$data_base/vills_DRC_STEP_CDD_ruggedness.dta", clear
  • $data_final/EA_HH.dta Stata
    build_pkg_datasets.do:187
    7_datawork/02. Dofiles/build_pkg_datasets.do, line 187 merge 1:m q4_cddid using "$data_final/EA_HH.dta"
3 more
  • $data_final/EP_HH_CH_VarConstructs.dta Stata
    build_pkg_datasets.do:8
    7_datawork/02. Dofiles/build_pkg_datasets.do, line 8 use "$data_final/EP_HH_CH_VarConstructs.dta", clear
  • $data_temp/acled_cdd_before.dta Stata
    build_pkg_datasets.do:702
    7_datawork/02. Dofiles/build_pkg_datasets.do, line 702 merge m:1 q4_cddid using "$data_temp/acled_cdd_before.dta", keep(1 3)
  • $data_temp/HH_Clean.dta Stata
    build_pkg_datasets.do:755
    7_datawork/02. Dofiles/build_pkg_datasets.do, line 755 use "$data_temp/HH_Clean.dta", clear

2 · The file pipeline — which script writes which file that a later script reads

25 scripts, in run order for the master script MasterDoFile_cg.do and the 23 scripts it runs (directly or through each other); the other 1 are not run by a master script and follow in file-name order; 10 hand-offs through 4 intermediate files; 4 files written and never read back (outputs).

7_datawork/02. Dofiles/build_pkg_datasets.do → 7_datawork/02. Dofiles/04_01_Balance Tables_cg.do: EP_HH_CH_VarConstructs_pkg.dta, HH_Clean_pkg.dta, baseline_pkg.dta7_datawork/02. Dofiles/build_pkg_datasets.do → 7_datawork/02. Dofiles/05_01_Analysis ITT- Main Tables_cg.do: EP_HH_CH_VarConstructs_pkg.dta7_datawork/02. Dofiles/build_pkg_datasets.do → 7_datawork/02. Dofiles/05_01_Analysis_ITT_Main_Graphs_cg.do: EP_HH_CH_VarConstructs_pkg.dta7_datawork/02. Dofiles/build_pkg_datasets.do → 7_datawork/02. Dofiles/05_04_Analysis ITT - Pooled Tables_cg.do: EP_HH_CH_VarConstructs_pkg.dta7_datawork/02. Dofiles/build_pkg_datasets.do → 7_datawork/02. Dofiles/05_06_Analysis_ANCOVA.do: EP_HH_CH_VarConstructs_pkg.dta, baseline_pkg.dta7_datawork/02. Dofiles/build_pkg_datasets.do → 7_datawork/02. Dofiles/06_02_Analysis_HET_compact.do: EP_HH_CH_VarConstructs_pkg.dta7_datawork/02. Dofiles/build_pkg_datasets.do → 7_datawork/02. Dofiles/07_07_lee_bounds_cg.do: EP_HH_CH_VarConstructs_pkg.dta7_datawork/02. Dofiles/build_pkg_datasets.do → 7_datawork/02. Dofiles/07_attrition_analysis.do: baseline_pkg.dta7_datawork/02. Dofiles/build_pkg_datasets.do → 7_datawork/02. Dofiles/08_PowerCalc.do: EP_HH_CH_VarConstructs_pkg.dta7_datawork/02. Dofiles/build_pkg_datasets.do → 7_datawork/02. Dofiles/09_spatial_analysis.do: EP_HH_CH_VarConstructs_vill_pkg.dta 7_datawork/02. Dofiles/MasterDoFile_cg.do 1. MasterDoFile_cg.do 7_datawork/02. Dofiles/build_pkg_datasets.do · reads 11 input files 2. build_pkg_datasets.do 7_datawork/02. Dofiles/04_01_Balance Tables_cg.do 3. 04_01_Balance Tables_cg.do 7_datawork/02. Dofiles/05_01_Analysis_ITT_Main_Graphs_cg.do · 2 estimations 4. 05_01_Analysis_ITT_Main_Graphs_cg.do 2 est.7_datawork/02. Dofiles/05_01_Analysis ITT- Main Tables_cg.do 5. 05_01_Analysis ITT- Main Tables_cg.do 7_datawork/02. Dofiles/programs_tables_3.do · 1 estimation 6. programs_tables_3.do 1 est.7_datawork/02. Dofiles/2a.fdr_qvalues.do 7. 2a.fdr_qvalues.do 7_datawork/02. Dofiles/write_transposed_table.do 8. write_transposed_table.do 7_datawork/02. Dofiles/05_04_Analysis ITT - Pooled Tables_cg.do 9. 05_04_Analysis ITT - Pooled Tables_cg.do 7_datawork/02. Dofiles/write_transposed_table_2.do 10. write_transposed_table_2.do 7_datawork/02. Dofiles/programs_tables_iv.do · 1 estimation 11. programs_tables_iv.do 1 est.7_datawork/02. Dofiles/write_transposed_table_iv.do 12. write_transposed_table_iv.do 7_datawork/02. Dofiles/07_attrition_analysis.do 13. 07_attrition_analysis.do 7_datawork/02. Dofiles/programs_tables_het_attrition.do · 1 estimation 14. programs_tables_het_attrition.do 1 est.7_datawork/02. Dofiles/write_attrition_table.do 15. write_attrition_table.do 7_datawork/02. Dofiles/05_06_Analysis_ANCOVA.do 16. 05_06_Analysis_ANCOVA.do 7_datawork/02. Dofiles/programs_tables_ancova.do · 1 estimation 17. programs_tables_ancova.do 1 est.7_datawork/02. Dofiles/write_transposed_ANCOVA.do 18. write_transposed_ANCOVA.do 7_datawork/02. Dofiles/07_07_lee_bounds_cg.do 19. 07_07_lee_bounds_cg.do 7_datawork/02. Dofiles/09_spatial_analysis.do · 7 estimations 20. 09_spatial_analysis.do 7 est.7_datawork/02. Dofiles/write_spatial_tables.do 21. write_spatial_tables.do 7_datawork/02. Dofiles/06_02_Analysis_HET_compact.do 22. 06_02_Analysis_HET_compact.do 7_datawork/02. Dofiles/programs_tables_het_panel.do · 1 estimation 23. programs_tables_het_panel.do 1 est.7_datawork/02. Dofiles/write_heterogeneity_table_compact.do 24. write_heterogeneity_table_compact.do 7_datawork/02. Dofiles/08_PowerCalc.do 25. 08_PowerCalc.do
  1. 1.7_datawork/02. Dofiles/MasterDoFile_cg.do master script
  2. 2.7_datawork/02. Dofiles/build_pkg_datasets.do reads 11 input files · 6 merges ·
    writes EP_HH_CH_VarConstructs_pkg.dta → read by 04_01_Balance Tables_cg.do, 05_01_Analysis_ITT_Main_Graphs_cg.do, 05_01_Analysis ITT- Main Tables_cg.do, 05_04_Analysis ITT - Pooled Tables_cg.do, 05_06_Analysis_ANCOVA.do, 07_07_lee_bounds_cg.do, 06_02_Analysis_HET_compact.do, 08_PowerCalc.do
    writes EP_HH_CH_VarConstructs_vill_pkg.dta → read by 09_spatial_analysis.do
    writes HH_Clean_pkg.dta → read by 04_01_Balance Tables_cg.do
    writes baseline_pkg.dta → read by 04_01_Balance Tables_cg.do, 07_attrition_analysis.do, 05_06_Analysis_ANCOVA.do
    writes (not read again): OSM_DRC_STEP_CDD_highway_highway_5km_pkg.dta, acled_cdd_before_pkg.dta, vills_DRC_STEP_CDD_climate_pkg.dta, vills_DRC_STEP_CDD_ruggedness_pkg.dta
  3. 3.7_datawork/02. Dofiles/04_01_Balance Tables_cg.do run by 7_datawork/02. Dofiles/MasterDoFile_cg.do line 98 2 merges ·
    reads what build_pkg_datasets.do wrote
  4. 4.7_datawork/02. Dofiles/05_01_Analysis_ITT_Main_Graphs_cg.do run by 7_datawork/02. Dofiles/MasterDoFile_cg.do line 107 2 estimations
    reads what build_pkg_datasets.do wrote
  5. 5.7_datawork/02. Dofiles/05_01_Analysis ITT- Main Tables_cg.do run by 7_datawork/02. Dofiles/MasterDoFile_cg.do line 125
    reads what build_pkg_datasets.do wrote
  6. 6.7_datawork/02. Dofiles/programs_tables_3.do run by 7_datawork/02. Dofiles/05_01_Analysis ITT- Main Tables_cg.do line 5 1 estimation
  7. 7.7_datawork/02. Dofiles/2a.fdr_qvalues.do run by 7_datawork/02. Dofiles/programs_tables_3.do line 159
  8. 8.7_datawork/02. Dofiles/write_transposed_table.do run by 7_datawork/02. Dofiles/05_01_Analysis ITT- Main Tables_cg.do line 66
  9. 9.7_datawork/02. Dofiles/05_04_Analysis ITT - Pooled Tables_cg.do run by 7_datawork/02. Dofiles/MasterDoFile_cg.do line 141
    reads what build_pkg_datasets.do wrote
  10. 10.7_datawork/02. Dofiles/write_transposed_table_2.do run by 7_datawork/02. Dofiles/05_04_Analysis ITT - Pooled Tables_cg.do line 73
  11. 11.7_datawork/02. Dofiles/programs_tables_iv.do run by 7_datawork/02. Dofiles/05_04_Analysis ITT - Pooled Tables_cg.do line 135 1 estimation
  12. 12.7_datawork/02. Dofiles/write_transposed_table_iv.do run by 7_datawork/02. Dofiles/05_04_Analysis ITT - Pooled Tables_cg.do line 182
  13. 13.7_datawork/02. Dofiles/07_attrition_analysis.do run by 7_datawork/02. Dofiles/MasterDoFile_cg.do line 153
    reads what build_pkg_datasets.do wrote
  14. 14.7_datawork/02. Dofiles/programs_tables_het_attrition.do run by 7_datawork/02. Dofiles/07_attrition_analysis.do line 13 1 estimation
  15. 15.7_datawork/02. Dofiles/write_attrition_table.do run by 7_datawork/02. Dofiles/07_attrition_analysis.do line 83
  16. 16.7_datawork/02. Dofiles/05_06_Analysis_ANCOVA.do run by 7_datawork/02. Dofiles/MasterDoFile_cg.do line 164 2 merges ·
    reads what build_pkg_datasets.do wrote
  17. 17.7_datawork/02. Dofiles/programs_tables_ancova.do run by 7_datawork/02. Dofiles/05_06_Analysis_ANCOVA.do line 14 1 estimation
  18. 18.7_datawork/02. Dofiles/write_transposed_ANCOVA.do run by 7_datawork/02. Dofiles/05_06_Analysis_ANCOVA.do line 98
  19. 19.7_datawork/02. Dofiles/07_07_lee_bounds_cg.do run by 7_datawork/02. Dofiles/MasterDoFile_cg.do line 176
    reads what build_pkg_datasets.do wrote
  20. 20.7_datawork/02. Dofiles/09_spatial_analysis.do run by 7_datawork/02. Dofiles/MasterDoFile_cg.do line 190 7 estimations
    reads what build_pkg_datasets.do wrote
  21. 21.7_datawork/02. Dofiles/write_spatial_tables.do run by 7_datawork/02. Dofiles/09_spatial_analysis.do line 100
  22. 22.7_datawork/02. Dofiles/06_02_Analysis_HET_compact.do run by 7_datawork/02. Dofiles/MasterDoFile_cg.do line 200
    reads what build_pkg_datasets.do wrote
  23. 23.7_datawork/02. Dofiles/programs_tables_het_panel.do run by 7_datawork/02. Dofiles/06_02_Analysis_HET_compact.do line 21 1 estimation
  24. 24.7_datawork/02. Dofiles/write_heterogeneity_table_compact.do run by 7_datawork/02. Dofiles/06_02_Analysis_HET_compact.do line 144
  25. 25.7_datawork/02. Dofiles/08_PowerCalc.do run by 7_datawork/02. Dofiles/MasterDoFile_cg.do line 211
    reads what build_pkg_datasets.do wrote

3 · Merges — 10 joins, 2 followed by a check of the merge result

JoinsHowOn keysCheck that followsWhere
ep_hh_ch_varconstructs ← vil_spatial merge m:1 q7h_village none
build_pkg_datasets.do:141
7_datawork/02. Dofiles/build_pkg_datasets.do, line 141 merge m:1 q7h_village using `vil_spatial', /// keepusing(ht20 hc20 near_treated min_dist_treated) nogen keep(1 3)
ea_hh ← ea_ch merge m:1 q4_cddid none
build_pkg_datasets.do:155
7_datawork/02. Dofiles/build_pkg_datasets.do, line 155 merge m:1 q4_cddid using "$data_base/EA_CH.dta", force
ep_hh ← ep_ch merge m:1 q4_cddid none
build_pkg_datasets.do:168
7_datawork/02. Dofiles/build_pkg_datasets.do, line 168 merge m:1 q4_cddid using "$data_base/EP_CH.dta", force
ep_hh ← ea merge 1:1 q4_cddid ren _merge merge_ep_ea
build_pkg_datasets.do:176
7_datawork/02. Dofiles/build_pkg_datasets.do, line 176 merge 1:1 q4_cddid using `ea'
ep_hh ← ea_hh merge 1:m q4_cddid none
build_pkg_datasets.do:187
7_datawork/02. Dofiles/build_pkg_datasets.do, line 187 merge 1:m q4_cddid using "$data_final/EA_HH.dta"
ep_hh ← acled_cdd_before merge m:1 q4_cddid replace tot_events = 0 if _merge == 1
build_pkg_datasets.do:702
7_datawork/02. Dofiles/build_pkg_datasets.do, line 702 merge m:1 q4_cddid using "$data_temp/acled_cdd_before.dta", keep(1 3)
ep_hh_ch_varconstructs_pkg ← hhid_baseline merge m:1 hhid none
04_01_Balance Tables_cg.do:27
7_datawork/02. Dofiles/04_01_Balance Tables_cg.do, line 27 merge m:1 hhid using `hhid_baseline', keep(3) nogen
hh_clean_pkg ← hhid_expost merge m:1 hhid none
04_01_Balance Tables_cg.do:61
7_datawork/02. Dofiles/04_01_Balance Tables_cg.do, line 61 merge m:1 hhid using `hhid_expost', keep(3) nogen
ep_hh_ch_varconstructs_pkg ← hhid_baseline merge m:1 hhid none
05_06_Analysis_ANCOVA.do:52
7_datawork/02. Dofiles/05_06_Analysis_ANCOVA.do, line 52 merge m:1 hhid using `hhid_baseline', keep(3) nogen
ep_hh_ch_varconstructs_pkg ← baseline_community merge m:1 q4_cddid none
05_06_Analysis_ANCOVA.do:55
7_datawork/02. Dofiles/05_06_Analysis_ANCOVA.do, line 55 merge m:1 q4_cddid using `baseline_community', gen(_merge_baseline) keep(3)

4 · The sample — 69 keep/drop steps, 9 variables winsorized or trimmed

Filters, by kind
time period ×1
  • drop if year_survey==2016
    05_04_Analysis ITT - Pooled Tables_cg.do:81
    7_datawork/02. Dofiles/05_04_Analysis ITT - Pooled Tables_cg.do, line 81 drop if year_survey==2016
value ranges ×3
  • keep if cdd_var_R != 3
    05_04_Analysis ITT - Pooled Tables_cg.do:194
    7_datawork/02. Dofiles/05_04_Analysis ITT - Pooled Tables_cg.do, line 194 keep if cdd_var_R != 3
  • keep if cdd_var_R != 2
    05_04_Analysis ITT - Pooled Tables_cg.do:248
    7_datawork/02. Dofiles/05_04_Analysis ITT - Pooled Tables_cg.do, line 248 keep if cdd_var_R != 2
  • drop if cdd_var_R == `drop_arm'
    07_07_lee_bounds_cg.do:133
    7_datawork/02. Dofiles/07_07_lee_bounds_cg.do, line 133 drop if cdd_var_R == `drop_arm'
category values ×53
  • drop if merge_init_list == 2
    build_pkg_datasets.do:47
    7_datawork/02. Dofiles/build_pkg_datasets.do, line 47 drop if merge_init_list == 2
  • keep if dataset_type == "EP HH"
    build_pkg_datasets.do:48
    7_datawork/02. Dofiles/build_pkg_datasets.do, line 48 keep if dataset_type == "EP HH"
  • drop if cdd_var_R == 4 | cdd_var_R == 5
    build_pkg_datasets.do:49
    7_datawork/02. Dofiles/build_pkg_datasets.do, line 49 drop if cdd_var_R == 4 | cdd_var_R == 5
  • drop if merge_init_list == 2
    build_pkg_datasets.do:137
    7_datawork/02. Dofiles/build_pkg_datasets.do, line 137 drop if merge_init_list == 2
  • keep if dataset_type == "EP HH"
    build_pkg_datasets.do:138
    7_datawork/02. Dofiles/build_pkg_datasets.do, line 138 keep if dataset_type == "EP HH"
  • drop if cdd_var_R == 4 | cdd_var_R == 5
    build_pkg_datasets.do:139
    7_datawork/02. Dofiles/build_pkg_datasets.do, line 139 drop if cdd_var_R == 4 | cdd_var_R == 5
  • drop if merge_init_list == 2
    04_01_Balance Tables_cg.do:22
    7_datawork/02. Dofiles/04_01_Balance Tables_cg.do, line 22 drop if merge_init_list == 2
  • keep if dataset_type == "EP HH" | dataset_type == "EP CH"
    04_01_Balance Tables_cg.do:23
    7_datawork/02. Dofiles/04_01_Balance Tables_cg.do, line 23 keep if dataset_type == "EP HH" | dataset_type == "EP CH"
  • first 8 of 53
indicator subsets ×6
  • drop if miss_survey_EA == 1
    build_pkg_datasets.do:192
    7_datawork/02. Dofiles/build_pkg_datasets.do, line 192 drop if miss_survey_EA == 1
  • keep if survey == 1
    07_07_lee_bounds_cg.do:121
    7_datawork/02. Dofiles/07_07_lee_bounds_cg.do, line 121 keep if survey == 1
  • keep if dataset_type == "EP HH" | has_survey == 0
    07_07_lee_bounds_cg.do:125
    7_datawork/02. Dofiles/07_07_lee_bounds_cg.do, line 125 keep if dataset_type == "EP HH" | has_survey == 0
  • keep if cdd_var == 1
    08_PowerCalc.do:54
    7_datawork/02. Dofiles/08_PowerCalc.do, line 54 keep if cdd_var == 1
  • keep if cdd_var == 1
    08_PowerCalc.do:154
    7_datawork/02. Dofiles/08_PowerCalc.do, line 154 keep if cdd_var == 1
  • keep if cdd_var == 1
    08_PowerCalc.do:251
    7_datawork/02. Dofiles/08_PowerCalc.do, line 251 keep if cdd_var == 1
missing values ×5
  • keep if cdd_var_R != .
    05_04_Analysis ITT - Pooled Tables_cg.do:23
    7_datawork/02. Dofiles/05_04_Analysis ITT - Pooled Tables_cg.do, line 23 keep if cdd_var_R != .
  • keep if cdd_var_R!=.
    05_04_Analysis ITT - Pooled Tables_cg.do:144
    7_datawork/02. Dofiles/05_04_Analysis ITT - Pooled Tables_cg.do, line 144 keep if cdd_var_R!=.
  • keep if cdd_var_R!=.
    05_04_Analysis ITT - Pooled Tables_cg.do:195
    7_datawork/02. Dofiles/05_04_Analysis ITT - Pooled Tables_cg.do, line 195 keep if cdd_var_R!=.
  • keep if cdd_var_R!=.
    05_04_Analysis ITT - Pooled Tables_cg.do:249
    7_datawork/02. Dofiles/05_04_Analysis ITT - Pooled Tables_cg.do, line 249 keep if cdd_var_R!=.
  • keep if cdd_var_R != .
    06_02_Analysis_HET_compact.do:52
    7_datawork/02. Dofiles/06_02_Analysis_HET_compact.do, line 52 keep if cdd_var_R != .
drops after a merge (_merge) ×1
  • drop if _merge == 2
    build_pkg_datasets.do:193
    7_datawork/02. Dofiles/build_pkg_datasets.do, line 193 drop if _merge == 2
Outliers
winsorize at 0/99 · 9 variables
q72b_conflictburglary_many q82b_governancehealth_many q83b_governanceeducation_many q84b_govagriculture_many q85b_governancesecurity_many q86b_governanceconflict_many q87b_govdemobilized_many q88b_govhumanrights_many q89b_governanceother_many
build_pkg_datasets.do:343
7_datawork/02. Dofiles/build_pkg_datasets.do, line 343 winsor2 q72b_conflictburglary_many, s(_w) c(0 99)
build_pkg_datasets.do:602
7_datawork/02. Dofiles/build_pkg_datasets.do, line 602 winsor2 q82b_governancehealth_many q83b_governanceeducation_many /// q84b_govagriculture_many q85b_governancesecurity_many /// q86b_governanceconflict_many q87b_govdemobilized_many /// q88b_govhumanrights_many q89b_governanceoth …
Missing values
set to zero ×46
  • q50g_hall_wall_qual → 0
    build_pkg_datasets.do:218
    7_datawork/02. Dofiles/build_pkg_datasets.do, line 218 replace q50g_hall_wall_qual = 0 if mi(q50g_hall_wall_qual) & !mi(q50g_hall_wall)
  • q50h_church_wall_qual → 0
    build_pkg_datasets.do:219
    7_datawork/02. Dofiles/build_pkg_datasets.do, line 219 replace q50h_church_wall_qual = 0 if mi(q50h_church_wall_qual) & !mi(q50h_church_wall)
  • infra_wall_qual → 0
    build_pkg_datasets.do:223
    7_datawork/02. Dofiles/build_pkg_datasets.do, line 223 replace infra_wall_qual = 0 if mi(infra_wall_qual)
  • q51g_hall_roof_qual → 0
    build_pkg_datasets.do:227
    7_datawork/02. Dofiles/build_pkg_datasets.do, line 227 replace q51g_hall_roof_qual = 0 if mi(q51g_hall_roof_qual) & !mi(q51g_hall_roof)
  • q51h_church_roof_qual → 0
    build_pkg_datasets.do:228
    7_datawork/02. Dofiles/build_pkg_datasets.do, line 228 replace q51h_church_roof_qual = 0 if mi(q51h_church_roof_qual) & !mi(q51h_church_roof)
  • infra_roof_qual → 0
    build_pkg_datasets.do:232
    7_datawork/02. Dofiles/build_pkg_datasets.do, line 232 replace infra_roof_qual = 0 if mi(infra_roof_qual)
dropped ×5
  • 06_02_Analysis_HET_compact.do:52
    7_datawork/02. Dofiles/06_02_Analysis_HET_compact.do, line 52 keep if cdd_var_R != .
  • 05_04_Analysis ITT - Pooled Tables_cg.do:23
    7_datawork/02. Dofiles/05_04_Analysis ITT - Pooled Tables_cg.do, line 23 keep if cdd_var_R != .
  • 05_04_Analysis ITT - Pooled Tables_cg.do:144
    7_datawork/02. Dofiles/05_04_Analysis ITT - Pooled Tables_cg.do, line 144 keep if cdd_var_R!=.
  • 05_04_Analysis ITT - Pooled Tables_cg.do:195
    7_datawork/02. Dofiles/05_04_Analysis ITT - Pooled Tables_cg.do, line 195 keep if cdd_var_R!=.
  • 05_04_Analysis ITT - Pooled Tables_cg.do:249
    7_datawork/02. Dofiles/05_04_Analysis ITT - Pooled Tables_cg.do, line 249 keep if cdd_var_R!=.
filled with a value ×3
  • infra_wall_qual → 1
    build_pkg_datasets.do:222
    7_datawork/02. Dofiles/build_pkg_datasets.do, line 222 replace infra_wall_qual = 1 if (q50g_hall_wall_qual==1 | q50h_church_wall_qual==1) & mi(infra_wall_qual)
  • infra_roof_qual → 1
    build_pkg_datasets.do:231
    7_datawork/02. Dofiles/build_pkg_datasets.do, line 231 replace infra_roof_qual = 1 if (q51g_hall_roof_qual==1 | q51h_church_roof_qual==1) & mi(infra_roof_qual)
  • q36_activityhour → r(mean)
    build_pkg_datasets.do:676
    7_datawork/02. Dofiles/build_pkg_datasets.do, line 676 replace q36_activityhour = r(mean) if mi(q36_activityhour) & q35_activity == 1

5 · Key variables — what enters the models, and where the code builds it

VariableUsed in models asBuilt by
LATE_cdd_var endogenous in 1 no statement builds it — a column of an input file, or made by a reshape/merge we do not trace
cdd_var_bi instrument in 1 no statement builds it — a column of an input file, or made by a reshape/merge we do not trace
pro_id regressor in 14 no statement builds it — a column of an input file, or made by a reshape/merge we do not trace
q8_projecttype regressor in 14 no statement builds it — a column of an input file, or made by a reshape/merge we do not trace
year_survey regressor in 14 no statement builds it — a column of an input file, or made by a reshape/merge we do not trace
married regressor in 9 no statement builds it — a column of an input file, or made by a reshape/merge we do not trace
q16_sex regressor in 9 no statement builds it — a column of an input file, or made by a reshape/merge we do not trace
q17_age regressor in 9 no statement builds it — a column of an input file, or made by a reshape/merge we do not trace
q19_reading regressor in 9 no statement builds it — a column of an input file, or made by a reshape/merge we do not trace
hc20 regressor in 6
hc20 = 0 (gen)
build_pkg_datasets.do:85
7_datawork/02. Dofiles/build_pkg_datasets.do, line 85 gen hc20 = 0
hc20 = _hc20 (replace)
build_pkg_datasets.do:113
7_datawork/02. Dofiles/build_pkg_datasets.do, line 113 replace hc20 = _hc20 in `i'
ht20 regressor in 6
ht20 = 0 (gen)
build_pkg_datasets.do:84
7_datawork/02. Dofiles/build_pkg_datasets.do, line 84 gen ht20 = 0
ht20 = _ht20 (replace)
build_pkg_datasets.do:107
7_datawork/02. Dofiles/build_pkg_datasets.do, line 107 replace ht20 = _ht20 in `i'
cdd_var_R regressor in 5
cdd_var_R = cdd_var (rename)
build_pkg_datasets.do:196
7_datawork/02. Dofiles/build_pkg_datasets.do, line 196 ren cdd_var cdd_var_R
treated_vil regressor in 3
treated_vil = (cdd_var_R == 2 | cdd_var_R == 3) (gen)
09_spatial_analysis.do:66
7_datawork/02. Dofiles/09_spatial_analysis.do, line 66 gen treated_vil = (cdd_var_R == 2 | cdd_var_R == 3)
treated_vil = (cdd_var_R == 2 ) (gen)
09_spatial_analysis.do:110
7_datawork/02. Dofiles/09_spatial_analysis.do, line 110 gen treated_vil = (cdd_var_R == 2 ) if cdd_var_R!=.
treated_vil = (cdd_var_R == 3 ) (gen)
09_spatial_analysis.do:154
7_datawork/02. Dofiles/09_spatial_analysis.do, line 154 gen treated_vil = (cdd_var_R == 3 ) if cdd_var_R!=.
near_treated regressor in 2
near_treated = (min_dist_treated < 20) (gen)
build_pkg_datasets.do:120
7_datawork/02. Dofiles/build_pkg_datasets.do, line 120 gen near_treated = (min_dist_treated < 20) if !missing(min_dist_treated)
treat1 regressor in 2
treat1 = (cdd_var_R==1) (gen)
05_01_Analysis_ITT_Main_Graphs_cg.do:23
7_datawork/02. Dofiles/05_01_Analysis_ITT_Main_Graphs_cg.do, line 23 gen treat1 = (cdd_var_R==1)

6 · Models, by the table or figure they feed — 14 estimations, 0 traced into 0 exhibits

Estimations not traced to a table or figure · 14
CommandOutcomeRegressors Fixed effectsStandard errorsWhere
reg
ols
`var' treat2 treat3 treat1 i.year_survey i.pro_id i.q8_projecttype q16_sex q17_age q19_reading married — cluster: q4_cddid
05_01_Analysis_ITT_Main_Graphs_cg.do:34
7_datawork/02. Dofiles/05_01_Analysis_ITT_Main_Graphs_cg.do, line 34 qui reg `var' treat2 treat3 treat1 /// i.year_survey i.pro_id i.q8_projecttype $controls, cl(q4_cddid) as we read it (macros filled in / loop expanded): qui reg `var' treat2 treat3 treat1 i.year_survey i.pro_id i.q8_projecttype q16_sex q17_age q19_reading married, cl(q4_cddid)
reg
ols
`var' treat2 treat3 treat1 i.year_survey i.pro_id i.q8_projecttype q16_sex q17_age q19_reading married — cluster: q4_cddid
05_01_Analysis_ITT_Main_Graphs_cg.do:39
7_datawork/02. Dofiles/05_01_Analysis_ITT_Main_Graphs_cg.do, line 39 qui reg `var' treat2 treat3 treat1 /// i.year_survey i.pro_id i.q8_projecttype $controls, cl(q4_cddid) level(90) as we read it (macros filled in / loop expanded): qui reg `var' treat2 treat3 treat1 i.year_survey i.pro_id i.q8_projecttype q16_sex q17_age q19_reading married, cl(q4_cddid) level(90)
reg
ols
`var' i.$treat_var i.year_survey i.pro_id i.q8_projecttype $controls — cluster: q4_cddid
programs_tables_3.do:66
7_datawork/02. Dofiles/programs_tables_3.do, line 66 reg `var' i.$treat_var i.year_survey i.pro_id i.q8_projecttype /// $controls, cluster(q4_cddid)
ivreg2
iv
`var' i.year_survey i.pro_id i.q8_projecttype $controls
endogenous: LATE_cdd_var
instruments: cdd_var_bi
— cluster: q4_cddid
programs_tables_iv.do:24
7_datawork/02. Dofiles/programs_tables_iv.do, line 24 ivreg2 `var' i.year_survey i.pro_id i.q8_projecttype /// $controls ($endog = $instrument), cluster(q4_cddid) as we read it (macros filled in / loop expanded): ivreg2 `var' i.year_survey i.pro_id i.q8_projecttype $controls (LATE_cdd_var = cdd_var_bi), cluster(q4_cddid)
reg
ols
`var' c.`factor'#i.$treat_var c.`factor' i.$treat_var i.year_survey i.pro_id i.q8_projecttype $controls — cluster: q4_cddid
programs_tables_het_attrition.do:24
7_datawork/02. Dofiles/programs_tables_het_attrition.do, line 24 reg `var' c.`factor'#i.$treat_var c.`factor' i.$treat_var /// i.year_survey i.pro_id i.q8_projecttype /// $controls, cluster(q4_cddid)
reg
ols
`var' i.$treat_var i.year_survey i.pro_id i.q8_projecttype $controls — cluster: q4_cddid
programs_tables_ancova.do:24
7_datawork/02. Dofiles/programs_tables_ancova.do, line 24 reg `var' i.$treat_var `baseline_var' /// i.year_survey i.pro_id i.q8_projecttype /// $controls, cluster(q4_cddid) as we read it (macros filled in / loop expanded): reg `var' i.$treat_var i.year_survey i.pro_id i.q8_projecttype $controls, cluster(q4_cddid)
reg
ols
`var' i.cdd_var_R c.near_treated c.near_treated#i.cdd_var_R i.year_survey i.pro_id i.q8_projecttype q16_sex q17_age q19_reading married — cluster: q4_cddid
09_spatial_analysis.do:35
7_datawork/02. Dofiles/09_spatial_analysis.do, line 35 reg `var' i.cdd_var_R c.near_treated c.near_treated#i.cdd_var_R /// i.year_survey i.pro_id i.q8_projecttype /// $controls, cluster(q4_cddid) as we read it (macros filled in / loop expanded): reg `var' i.cdd_var_R c.near_treated c.near_treated#i.cdd_var_R i.year_survey i.pro_id i.q8_projecttype q16_sex q17_age q19_reading married, cluster(q4_cddid)
run 6× in a loop (var=MIND_INFRA; var=MIND_SOCIALCO; var=MIND_CONFL_BTW…)
reg
ols
`var' treated_vil hc20 ht20 i.year_survey i.pro_id i.q8_projecttype q16_sex q17_age q19_reading married — cluster: q4_cddid
09_spatial_analysis.do:73
7_datawork/02. Dofiles/09_spatial_analysis.do, line 73 reg `var' treated_vil hc20 ht20 /// i.year_survey i.pro_id i.q8_projecttype /// $controls, cluster(q4_cddid) as we read it (macros filled in / loop expanded): reg `var' treated_vil hc20 ht20 i.year_survey i.pro_id i.q8_projecttype q16_sex q17_age q19_reading married, cluster(q4_cddid)
run 6× in a loop (var=MIND_INFRA; var=MIND_SOCIALCO; var=MIND_CONFL_BTW…)
reg
ols
`var' i.cdd_var_R hc20 ht20 i.year_survey i.pro_id i.q8_projecttype q16_sex q17_age q19_reading married — cluster: q4_cddid
09_spatial_analysis.do:80
7_datawork/02. Dofiles/09_spatial_analysis.do, line 80 reg `var' i.cdd_var_R hc20 ht20 /// i.year_survey i.pro_id i.q8_projecttype /// $controls, cluster(q4_cddid) as we read it (macros filled in / loop expanded): reg `var' i.cdd_var_R hc20 ht20 i.year_survey i.pro_id i.q8_projecttype q16_sex q17_age q19_reading married, cluster(q4_cddid)
run 6× in a loop (var=MIND_INFRA; var=MIND_SOCIALCO; var=MIND_CONFL_BTW…)
reg
ols
`var' treated_vil hc20 ht20 i.year_survey i.pro_id i.q8_projecttype q16_sex q17_age q19_reading married — cluster: q4_cddid
09_spatial_analysis.do:118
7_datawork/02. Dofiles/09_spatial_analysis.do, line 118 reg `var' treated_vil hc20 ht20 /// i.year_survey i.pro_id i.q8_projecttype /// $controls, cluster(q4_cddid) as we read it (macros filled in / loop expanded): reg `var' treated_vil hc20 ht20 i.year_survey i.pro_id i.q8_projecttype q16_sex q17_age q19_reading married, cluster(q4_cddid)
run 6× in a loop (var=MIND_INFRA; var=MIND_SOCIALCO; var=MIND_CONFL_BTW…)
reg
ols
`var' i.cdd_var_R hc20 ht20 i.year_survey i.pro_id i.q8_projecttype q16_sex q17_age q19_reading married — cluster: q4_cddid
09_spatial_analysis.do:125
7_datawork/02. Dofiles/09_spatial_analysis.do, line 125 reg `var' i.cdd_var_R hc20 ht20 /// i.year_survey i.pro_id i.q8_projecttype /// $controls, cluster(q4_cddid) as we read it (macros filled in / loop expanded): reg `var' i.cdd_var_R hc20 ht20 i.year_survey i.pro_id i.q8_projecttype q16_sex q17_age q19_reading married, cluster(q4_cddid)
run 6× in a loop (var=MIND_INFRA; var=MIND_SOCIALCO; var=MIND_CONFL_BTW…)
reg
ols
`var' treated_vil hc20 ht20 i.year_survey i.pro_id i.q8_projecttype q16_sex q17_age q19_reading married — cluster: q4_cddid
09_spatial_analysis.do:161
7_datawork/02. Dofiles/09_spatial_analysis.do, line 161 reg `var' treated_vil hc20 ht20 /// i.year_survey i.pro_id i.q8_projecttype /// $controls, cluster(q4_cddid) as we read it (macros filled in / loop expanded): reg `var' treated_vil hc20 ht20 i.year_survey i.pro_id i.q8_projecttype q16_sex q17_age q19_reading married, cluster(q4_cddid)
run 6× in a loop (var=MIND_INFRA; var=MIND_SOCIALCO; var=MIND_CONFL_BTW…)
reg
ols
`var' i.cdd_var_R hc20 ht20 i.year_survey i.pro_id i.q8_projecttype q16_sex q17_age q19_reading married — cluster: q4_cddid
09_spatial_analysis.do:168
7_datawork/02. Dofiles/09_spatial_analysis.do, line 168 reg `var' i.cdd_var_R hc20 ht20 /// i.year_survey i.pro_id i.q8_projecttype /// $controls, cluster(q4_cddid) as we read it (macros filled in / loop expanded): reg `var' i.cdd_var_R hc20 ht20 i.year_survey i.pro_id i.q8_projecttype q16_sex q17_age q19_reading married, cluster(q4_cddid)
run 6× in a loop (var=MIND_INFRA; var=MIND_SOCIALCO; var=MIND_CONFL_BTW…)
reg
ols
`var' $treat_var `factor' `inter' i.year_survey i.pro_id i.q8_projecttype $controls — cluster: q4_cddid
programs_tables_het_panel.do:10
7_datawork/02. Dofiles/programs_tables_het_panel.do, line 10 reg `var' $treat_var `factor' `inter' i.year_survey i.pro_id i.q8_projecttype /// $controls, cluster(q4_cddid)
Tables and figures the code writes: $tbl_outfile
write_transposed_table_iv.do:68
7_datawork/02. Dofiles/write_transposed_table_iv.do, line 68 file open fh using "$tbl_outfile", write replace
· `outfile
07_07_lee_bounds_cg.do:23
7_datawork/02. Dofiles/07_07_lee_bounds_cg.do, line 23 file open fh using "`outfile'", write replace
· reg_SPATIAL_02_merfeld$arm.tex
write_spatial_tables.do:105
7_datawork/02. Dofiles/write_spatial_tables.do, line 105 file open fh using "$out/reg_SPATIAL_02_merfeld$arm.tex", write replace
· results.xls
05_01_Analysis_ITT_Main_Graphs_cg.do:58
7_datawork/02. Dofiles/05_01_Analysis_ITT_Main_Graphs_cg.do, line 58 putexcel set "$out/results.xls", sheet("graph") replace
· FAM_ALL_cg.pdf
05_01_Analysis_ITT_Main_Graphs_cg.do:95
7_datawork/02. Dofiles/05_01_Analysis_ITT_Main_Graphs_cg.do, line 95 graph export "$out/FAM_ALL_cg.pdf", replace
· PC_AssetIndex.pdf
08_PowerCalc.do:327
7_datawork/02. Dofiles/08_PowerCalc.do, line 327 graph export "$out/PC_AssetIndex.pdf", replace
· PC_NbrInfra.pdf
08_PowerCalc.do:230
7_datawork/02. Dofiles/08_PowerCalc.do, line 230 graph export "$out/PC_NbrInfra.pdf", replace
· PC_WthConflicts.pdf
08_PowerCalc.do:130
7_datawork/02. Dofiles/08_PowerCalc.do, line 130 graph export "$out/PC_WthConflicts.pdf", replace

7 · Figures: how each is drawn — 4 figures in the code (command, layers, options, the file it is saved to)

line 3 · coefficient plot 1
commandlayersvariables optionssaved aswhere
coefplot
coefficient plot
coefplot + coefplot estimates matrix(A1_12[1,]), matrix(A1_22[1,]) xtitle SD · xline 0 · ci rcap · legend order(3 CDD 6 CDD+) ring(0) bmargin(small) position(1) size(small) rows(8) FAM_ALL_cg.pdf
05_01_Analysis_ITT_Main_Graphs_cg.do:85
7_datawork/02. Dofiles/05_01_Analysis_ITT_Main_Graphs_cg.do, line 85 coefplot matrix(A1_12[1,]) matrix(A1_22[1,]) /// , ci((2 3)(4 5)) xline(0, lwidth(medium) lcolor(gray) lpattern(solid)) /// ylabel(, labsize(small)) graphregion(margin(l=25)) /// coeflabels(r1="Infrastructure …
–93
twoway
line
line + line + line + line y power_01icc2, power_02icc2, power_03icc2, power_04icc2 x power_01icc1, power_02icc1, power_03icc1, +1 more xtitle Effect Size (SD) {&rarr} · ytitle Power · yline .8 · legend region(lc(none) fc(none)) PC_WthConflicts.pdf
08_PowerCalc.do:120
7_datawork/02. Dofiles/08_PowerCalc.do, line 120 tw (line power_01icc2 power_01icc1, lpattern(vshortdash) lc(black)) /// (line power_02icc2 power_02icc1, lpattern(dash) lc(black)) /// (line power_03icc2 power_03icc1, lc(black)) /// (line power_04icc2 power …
–128
twoway
line
line + line + line + line y power_01icc2, power_02icc2, power_03icc2, power_04icc2 x power_01icc1, power_02icc1, power_03icc1, +1 more xtitle Effect Size (SD) {&rarr} · ytitle Power · yline .8 · legend region(lc(none) fc(none)) PC_NbrInfra.pdf
08_PowerCalc.do:220
7_datawork/02. Dofiles/08_PowerCalc.do, line 220 tw (line power_01icc2 power_01icc1, lpattern(vshortdash) lc(black)) /// (line power_02icc2 power_02icc1, lpattern(dash) lc(black)) /// (line power_03icc2 power_03icc1, lc(black)) /// (line power_04icc2 power …
–228
twoway
line
line + line + line + line y power_01icc2, power_02icc2, power_03icc2, power_04icc2 x power_01icc1, power_02icc1, power_03icc1, +1 more xtitle Effect Size (SD) {&rarr} · ytitle Power · yline .8 · legend region(lc(none) fc(none)) PC_AssetIndex.pdf
08_PowerCalc.do:317
7_datawork/02. Dofiles/08_PowerCalc.do, line 317 tw (line power_01icc2 power_01icc1, lpattern(vshortdash) lc(black)) /// (line power_02icc2 power_02icc1, lpattern(dash) lc(black)) /// (line power_03icc2 power_03icc1, lc(black)) /// (line power_04icc2 power …
–325