American Economic Review · 2026 · 10.1257/aer.20211820
Real Credit Cycles
Pedro Bordalo; Nicola Gennaioli; Andrei Shleifer; Stephen J. Terry
The research recipe, read from the replication code
openicpsr · package
· fortran, shell, stata, matlab
2009–2018
sample period in the code
76
keep/drop statements
36
winsorizations
33
missing-data rules
0
de-duplications
22
distinct estimations
Sample period in the code: the latest start and earliest end its separate keep/drop filters impose —
step3_micro_results.do:353 and 3 other files.
These tiles count distinct estimations (one per command, method, inference, fixed effects and file) and keep/drop statements.
"How the code gets from data to results" below counts every estimating statement (84)
and keep/drop statements plus winsorized variables (86).
1 · Data and structure
Databases read: none detected
Panel declared as:
gvkey × fyear (annual); ind × fyear (annual); firm × time2 · How the sample is built
- drop missing data ×22
- keep category value ×13
- keep indicator subset ×9
- keep value range ×8
- drop industry ×8
- keep time period ×8
- keep observation position ×3
- keep missing data ×3
Reshaping:
collapse to a coarser unit ×7
3 · Design and validation
Identification: instrumental variables
IV diagnostics: first stage f
Standard measures:
Capital Expenditure
4 · What it estimates
| Command | Method | Fixed effects absorbed | Inference | File |
|---|---|---|---|---|
|
iv | ind | default | step3_industry_regs.do |
|
panel fe | ind | cluster by ind | step3_industry_regs.do |
|
panel fe | ind | cluster by ind | step3_industry_regs.do |
|
iv | ind | cluster by ind | step3_industry_regs.do |
|
panel fe | cluster by ind | step3_industry_regs.do | |
|
iv | ind | default | step3_industry_regs_2digit.do |
|
panel fe | ind | cluster by ind | step3_industry_regs_2digit.do |
|
panel fe | gvkey, fyear | cluster by gvkey | step3_micro_results.do |
|
panel fe | fyear | cluster by gvkey | step3_micro_results.do |
|
panel fe | fyear | default | step3_micro_results.do |
|
ols | default | step3_micro_results.do | |
|
iv | fyear | cluster by gvkey | step3_micro_results.do |
|
panel fe | fyear | cluster by gvkey | step3_micro_results.do |
|
panel fe | gvkey, fyear | cluster by gvkey | step3_moments_prep.do |
|
panel fe | fyear | default | step3_moments_prep.do |
|
ols | default | step3_moments_prep.do | |
|
ols | default | read_diag.do | |
|
ols | default | read_diag_fin_disruptions.do | |
|
panel fe | indnum | cluster by indnum | read_diag_macro_regs.do |
|
panel fe | time | cluster by firm | read_firms.do |
|
iv | time | cluster by firm | read_firms.do |
|
ols | default | read_diag_fin_disruptions.do |
5 · What it produces
5 table files and 0 figure files
(txt 5);
40 estimates traced from the model that produced them into the exhibit that reports them.
TABLE_6_DE.txtTABLE_6_RE.txtTABLE_6.txtFIN_DISRUPTIONS_PATHS.txtR2_VALUES.txtHow the code gets from data to results own page
46
scripts
92
input files
40
file hand-offs
16
merges
86
sample steps
84
estimations
1 · Data in — files the code reads and no script of the package writes
Datasets this package uses (item detector / README):
Compustat, CRSP/Compustat Merged (CCM), CRSP US Stock Database
I/B/E/S
3 files
../DATA/IBES_FCSTS_AND_ACTUAL/IBES_ADJUSTMENT_FACTOR_26_SEP_2019_VINTAGE/8a2d333bc6be387b.csvCSVstep0_read_ibes_adjustment_factors.do:11
EMPIRICS/CODE/step0_read_ibes_adjustment_factors.do, line 11 insheet using "../DATA/IBES_FCSTS_AND_ACTUAL/IBES_ADJUSTMENT_FACTOR_26_SEP_2019_VINTAGE/8a2d333bc6be387b.csv", names../DATA/IBES_FCSTS_AND_ACTUAL/IBES_DETAIL_ACTUALS_26_SEP_2019_VINTAGE/2ce1081f48744436.csvCSVstep0_read_ibes_actuals.do:11
EMPIRICS/CODE/step0_read_ibes_actuals.do, line 11 insheet using "../DATA/IBES_FCSTS_AND_ACTUAL/IBES_DETAIL_ACTUALS_26_SEP_2019_VINTAGE/2ce1081f48744436.csv", names../DATA/IBES_FCSTS_AND_ACTUAL/IBES_GUIDANCE_DATA_5_MAY_2017_VINTAGE/60878dfdd5c60851.csvCSVstep0_read_ibes_guidance.do:11
EMPIRICS/CODE/step0_read_ibes_guidance.do, line 11 insheet using "../DATA/IBES_FCSTS_AND_ACTUAL/IBES_GUIDANCE_DATA_5_MAY_2017_VINTAGE/60878dfdd5c60851.csv", names
../DATA/COMPUSTAT_CRSP_MERGED/RAW_DATA_5_FEB_2020_VINTAGE/9c43b8480b3af26f.csvCSVstep0_read_compustat_crsp.do:9
EMPIRICS/CODE/step0_read_compustat_crsp.do, line 9 insheet using "../DATA/COMPUSTAT_CRSP_MERGED/RAW_DATA_5_FEB_2020_VINTAGE/9c43b8480b3af26f.csv"
CRSP US Stock Database
1 file
../DATA/WRDS_BOND_CRSP_LINK_11_MAR_2020_VINTAGE/03efa24807f83d2b.csvCSVstep0_read_wrds_bond_CRSP_link.do:11
EMPIRICS/CODE/step0_read_wrds_bond_CRSP_link.do, line 11 insheet using "../DATA/WRDS_BOND_CRSP_LINK_11_MAR_2020_VINTAGE/03efa24807f83d2b.csv", names
Other input files
87 files
A0.txttext · read by 4 scriptsread_diag_firms.m:39
MODEL/GE_MODEL/DE/read_diag_firms.m, line 39 A0 = importdata('A0.txt');Asim.txttext · read by 4 scriptsread_diag_firms.m:119
MODEL/GE_MODEL/DE/read_diag_firms.m, line 119 Asim = importdata('Asim.txt');Asimpos.txttext · read by 4 scriptsread_diag_firms.m:120
MODEL/GE_MODEL/DE/read_diag_firms.m, line 120 Asimpos = importdata('Asimpos.txt');b0.txttext · read by 4 scriptsread_diag_firms.m:36
MODEL/GE_MODEL/DE/read_diag_firms.m, line 36 b0 = importdata('b0.txt');Bsim.txttext · read by 4 scriptsread_diag_firms.m:126
MODEL/GE_MODEL/DE/read_diag_firms.m, line 126 Bsim = importdata('Bsim.txt');BtoKsim.txttext · read by 4 scriptsread_diag_firms.m:127
MODEL/GE_MODEL/DE/read_diag_firms.m, line 127 BtoKsim = importdata('BtoKsim.txt');constants.txttext · read by 4 scriptsread_diag_firms.m:16
MODEL/GE_MODEL/DE/read_diag_firms.m, line 16 constantsvec = importdata('constants.txt');dfpolind.txttext · read by 4 scriptsread_diag_firms.m:76
MODEL/GE_MODEL/DE/read_diag_firms.m, line 76 dfpolindvec = importdata('dfpolind.txt');
72 more
dfsim.txttext · read by 4 scriptsread_diag_firms.m:125
MODEL/GE_MODEL/DE/read_diag_firms.m, line 125 dfsim = importdata('dfsim.txt');dist.txttext · read by 4 scriptsread_diag_firms.m:78
MODEL/GE_MODEL/DE/read_diag_firms.m, line 78 distvec = importdata('dist.txt');distb.txttext · read by 4 scriptsread_diag_firms.m:72
MODEL/GE_MODEL/DE/read_diag_firms.m, line 72 distb = importdata('distb.txt');distk.txttext · read by 4 scriptsread_diag_firms.m:71
MODEL/GE_MODEL/DE/read_diag_firms.m, line 71 distk = importdata('distk.txt');endogind.txttext · read by 4 scriptsread_diag_firms.m:67
MODEL/GE_MODEL/DE/read_diag_firms.m, line 67 endogind = importdata('endogind.txt');GMMmodelmom.txttext · read by 4 scriptscompute_SE.m:15
MODEL/ESTIMATION/DE/compute_SE.m, line 15 GMMmom = importdata('GMMmodelmom.txt');GMMparam.txttext · read by 4 scriptscompute_SE.m:16
MODEL/ESTIMATION/DE/compute_SE.m, line 16 GMMparam = importdata('GMMparam.txt');Isim.txttext · read by 4 scriptsread_diag_firms.m:123
MODEL/GE_MODEL/DE/read_diag_firms.m, line 123 Isim = importdata('Isim.txt');k0.txttext · read by 4 scriptsread_diag_firms.m:35
MODEL/GE_MODEL/DE/read_diag_firms.m, line 35 k0 = importdata('k0.txt');kbpolind.txttext · read by 4 scriptsread_diag_firms.m:75
MODEL/GE_MODEL/DE/read_diag_firms.m, line 75 kbpolindvec = importdata('kbpolind.txt');Ksim.txttext · read by 4 scriptsread_diag_firms.m:122
MODEL/GE_MODEL/DE/read_diag_firms.m, line 122 Ksim = importdata('Ksim.txt');Nsim.txttext · read by 4 scriptsread_diag_firms.m:131
MODEL/GE_MODEL/DE/read_diag_firms.m, line 131 Nsim = importdata('Nsim.txt');pr_mat_A.txttext · read by 4 scriptsread_diag_firms.m:40
MODEL/GE_MODEL/DE/read_diag_firms.m, line 40 pr_mat_A = importdata('pr_mat_A.txt');pr_mat_A_theta.txttext · read by 4 scriptsread_diag_firms.m:55
MODEL/GE_MODEL/DE/read_diag_firms.m, line 55 pr_mat_A_thetavec = importdata('pr_mat_A_theta.txt');pr_mat_z.txttext · read by 4 scriptsread_diag_firms.m:38
MODEL/GE_MODEL/DE/read_diag_firms.m, line 38 pr_mat_z = importdata('pr_mat_z.txt');pr_mat_z_theta.txttext · read by 4 scriptsread_diag_firms.m:43
MODEL/GE_MODEL/DE/read_diag_firms.m, line 43 pr_mat_z_thetavec = importdata('pr_mat_z_theta.txt');qmat.txttext · read by 4 scriptsread_diag_firms.m:77
MODEL/GE_MODEL/DE/read_diag_firms.m, line 77 qmatvec = importdata('qmat.txt');qsim.txttext · read by 4 scriptsread_diag_firms.m:124
MODEL/GE_MODEL/DE/read_diag_firms.m, line 124 qsim = importdata('qsim.txt');retbondsim.txttext · read by 4 scriptsread_diag_firms.m:130
MODEL/GE_MODEL/DE/read_diag_firms.m, line 130 retbondsim = importdata('retbondsim.txt');sdMPKsim.txttext · read by 4 scriptsread_diag_firms.m:134
MODEL/GE_MODEL/DE/read_diag_firms.m, line 134 sdMPKsim = importdata('sdMPKsim.txt');spread0.txttext · read by 4 scriptsread_diag_firms.m:41
MODEL/GE_MODEL/DE/read_diag_firms.m, line 41 spread0=importdata('spread0.txt');spreadsim.txttext · read by 4 scriptsread_diag_firms.m:129
MODEL/GE_MODEL/DE/read_diag_firms.m, line 129 spreadsim = importdata('spreadsim.txt');Vtheta.txttext · read by 4 scriptsread_diag_firms.m:74
MODEL/GE_MODEL/DE/read_diag_firms.m, line 74 Vthetavec=importdata('Vtheta.txt');Ysim.txttext · read by 4 scriptsread_diag_firms.m:121
MODEL/GE_MODEL/DE/read_diag_firms.m, line 121 Ysim = importdata('Ysim.txt');z0.txttext · read by 4 scriptsread_diag_firms.m:37
MODEL/GE_MODEL/DE/read_diag_firms.m, line 37 z0 = importdata('z0.txt');bfirm.txttext · read by 3 scriptsread_diag_firms.m:198
MODEL/SIMULATION/DE/LONG_SIM/read_diag_firms.m, line 198 bfirmvec = importdata('bfirm.txt');bfirmpos.txttext · read by 3 scriptsread_diag_firms.m:193
MODEL/SIMULATION/DE/LONG_SIM/read_diag_firms.m, line 193 bfirmposvec = importdata('bfirmpos.txt');dfirmpos.txttext · read by 3 scriptsread_diag_firms.m:191
MODEL/SIMULATION/DE/LONG_SIM/read_diag_firms.m, line 191 dfirmposvec = importdata('dfirmpos.txt');endogfirmpos.txttext · read by 3 scriptsread_diag_firms.m:190
MODEL/SIMULATION/DE/LONG_SIM/read_diag_firms.m, line 190 endogfirmposvec = importdata('endogfirmpos.txt');fefirm.txttext · read by 3 scriptsread_diag_firms.m:199
MODEL/SIMULATION/DE/LONG_SIM/read_diag_firms.m, line 199 fefirmvec = importdata('fefirm.txt');FEsim.txttext · read by 3 scriptsread_diag_firms.m:184
MODEL/SIMULATION/DE/LONG_SIM/read_diag_firms.m, line 184 FEsim = importdata('FEsim.txt');GMMobj.txttext · read by 3 scriptsmodel_fit.m:72
MODEL/ESTIMATION/DE/model_fit.m, line 72 GMMobj = importdata('GMMobj.txt');ifirm.txttext · read by 3 scriptsread_diag_firms.m:196
MODEL/SIMULATION/DE/LONG_SIM/read_diag_firms.m, line 196 ifirmvec = importdata('ifirm.txt');kfirm.txttext · read by 3 scriptsread_diag_firms.m:197
MODEL/SIMULATION/DE/LONG_SIM/read_diag_firms.m, line 197 kfirmvec = importdata('kfirm.txt');kfirmpos.txttext · read by 3 scriptsread_diag_firms.m:192
MODEL/SIMULATION/DE/LONG_SIM/read_diag_firms.m, line 192 kfirmposvec = importdata('kfirmpos.txt');pifcstfirm.txttext · read by 3 scriptsread_diag_firms.m:195
MODEL/SIMULATION/DE/LONG_SIM/read_diag_firms.m, line 195 pifcstfirmvec = importdata('pifcstfirm.txt');pifirm.txttext · read by 3 scriptsread_diag_firms.m:194
MODEL/SIMULATION/DE/LONG_SIM/read_diag_firms.m, line 194 pifirmvec = importdata('pifirm.txt');Pifsim.txttext · read by 3 scriptsread_diag_firms.m:186
MODEL/SIMULATION/DE/LONG_SIM/read_diag_firms.m, line 186 Pifsim = importdata('Pifsim.txt');Pisim.txttext · read by 3 scriptsread_diag_firms.m:185
MODEL/SIMULATION/DE/LONG_SIM/read_diag_firms.m, line 185 Pisim = importdata('Pisim.txt');qfirm.txttext · read by 3 scriptsread_diag_firms.m:200
MODEL/SIMULATION/DE/LONG_SIM/read_diag_firms.m, line 200 qfirmvec = importdata('qfirm.txt');Vdtheta.txttext · read by 3 scriptsread_diag_firms.m:126
MODEL/SIMULATION/DE/LONG_SIM/read_diag_firms.m, line 126 Vdthetavec = importdata('Vdtheta.txt');Vndtheta.txttext · read by 3 scriptsread_diag_firms.m:80
MODEL/SIMULATION/DE/LONG_SIM/read_diag_firms.m, line 80 Vndthetavec=importdata('Vndtheta.txt');zfirmpos.txttext · read by 3 scriptsread_diag_firms.m:189
MODEL/SIMULATION/DE/LONG_SIM/read_diag_firms.m, line 189 zfirmposvec = importdata('zfirmpos.txt');AsimIRF.txttext · read by 2 scriptsread_diag_firms.m:259
MODEL/GE_MODEL/DE/read_diag_firms.m, line 259 AsimIRFvec = importdata('AsimIRF.txt');GMMdiag.txttext · read by 2 scriptsmodel_fit.m:71
MODEL/ESTIMATION/DE/model_fit.m, line 71 GMMdiag = importdata('GMMdiag.txt');IsimIRF.txttext · read by 2 scriptsread_diag_firms.m:261
MODEL/GE_MODEL/DE/read_diag_firms.m, line 261 IsimIRFvec = importdata('IsimIRF.txt');../../RE/LONG_SIM/FIN_DISRUPTIONS_PATHS.txttextmake_fin_disruption_paths_fig.m:15
MODEL/SIMULATION/DE/LONG_SIM/make_fin_disruption_paths_fig.m, line 15 CRISIS_LEVEL_RAT = importdata(RE_filename);../../RE/LONG_SIM/Vrat.matMATLABread_diag_firms.m:142
MODEL/SIMULATION/DE/LONG_SIM/read_diag_firms.m, line 142 load(Vratfilename)../DATA/FRED_CONSTANT_MATURITY_TREASURY_RATES_30_MAR_2020_VINTAGE/treasury_rates.csvCSVstep0_read_fred_treasury.do:9
EMPIRICS/CODE/step0_read_fred_treasury.do, line 9 insheet using "../DATA/FRED_CONSTANT_MATURITY_TREASURY_RATES_30_MAR_2020_VINTAGE/treasury_rates.csv"../DATA/FRED_QUARTERLY_SERIES_VINTAGE_16_JUNE_2020/GDPC1.csvCSVstep3_quarterly_matching_series.do:23
EMPIRICS/CODE/step3_quarterly_matching_series.do, line 23 insheet using "../DATA/FRED_QUARTERLY_SERIES_VINTAGE_16_JUNE_2020/GDPC1.csv", clear../DATA/FRED_QUARTERLY_SERIES_VINTAGE_16_JUNE_2020/GDPDEF.csvCSVstep3_quarterly_matching_series.do:52
EMPIRICS/CODE/step3_quarterly_matching_series.do, line 52 insheet using "../DATA/FRED_QUARTERLY_SERIES_VINTAGE_16_JUNE_2020/GDPDEF.csv", clear../DATA/FRED_QUARTERLY_SERIES_VINTAGE_16_JUNE_2020/PNFIC1.csvCSVstep3_quarterly_matching_series.do:10
EMPIRICS/CODE/step3_quarterly_matching_series.do, line 10 insheet using "../DATA/FRED_QUARTERLY_SERIES_VINTAGE_16_JUNE_2020/PNFIC1.csv"../DATA/FRED_QUARTERLY_SERIES_VINTAGE_16_JUNE_2020/QUSNAMUSDA.csvCSVstep3_quarterly_matching_series.do:38
EMPIRICS/CODE/step3_quarterly_matching_series.do, line 38 insheet using "../DATA/FRED_QUARTERLY_SERIES_VINTAGE_16_JUNE_2020/QUSNAMUSDA.csv", clear../DATA/FRED_REAL_GROSS_DOMESTIC_PRODUCT_31_MAR_2020_VINTAGE/GDPCA.csvCSVstep0_process_real_gdp.do:9
EMPIRICS/CODE/step0_process_real_gdp.do, line 9 import delimited using "../DATA/FRED_REAL_GROSS_DOMESTIC_PRODUCT_31_MAR_2020_VINTAGE/GDPCA.csv"../DATA/IBES_CRSP_LINK_WRDS_5_MAR_2020_VINTAGE/RAW_DATA/24afcef34577c26b.csvCSVstep0_read_crsp_ibes_link.do:9
EMPIRICS/CODE/step0_read_crsp_ibes_link.do, line 9 insheet using "../DATA/IBES_CRSP_LINK_WRDS_5_MAR_2020_VINTAGE/RAW_DATA/24afcef34577c26b.csv", names../DATA/JOHN_FERNALD_TFP_VINTAGE_4_JUNE_2020/dtfp.csvCSVstep3_quarterly_matching_series.do:65
EMPIRICS/CODE/step3_quarterly_matching_series.do, line 65 insheet using "../DATA/JOHN_FERNALD_TFP_VINTAGE_4_JUNE_2020/dtfp.csv", clear../DATA/WRDS_BOND_RETURN_DATA_11_MAR_2020_VINTAGE/ff2d5b15e65bd9e5.csvCSVstep0_read_wrds_bond_return.do:11
EMPIRICS/CODE/step0_read_wrds_bond_return.do, line 11 insheet using "../DATA/WRDS_BOND_RETURN_DATA_11_MAR_2020_VINTAGE/ff2d5b15e65bd9e5.csv", names./BASELINE/A0.txttextcompute_IRF_figs.m:65
IRFS/DE/BASELINE_FIGS/compute_IRF_figs.m, line 65 A0 = importdata('./BASELINE/A0.txt');./BASELINE/b0.txttextcompute_IRF_figs.m:62
IRFS/DE/BASELINE_FIGS/compute_IRF_figs.m, line 62 b0 = importdata('./BASELINE/b0.txt');./BASELINE/constants.txttextcompute_IRF_figs.m:43
IRFS/DE/BASELINE_FIGS/compute_IRF_figs.m, line 43 constantsvec = importdata('./BASELINE/constants.txt');./BASELINE/endogind.txttextcompute_IRF_figs.m:93
IRFS/DE/BASELINE_FIGS/compute_IRF_figs.m, line 93 endogind = importdata('./BASELINE/endogind.txt');./BASELINE/k0.txttextcompute_IRF_figs.m:61
IRFS/DE/BASELINE_FIGS/compute_IRF_figs.m, line 61 k0 = importdata('./BASELINE/k0.txt');./BASELINE/pr_mat_A.txttextcompute_IRF_figs.m:66
IRFS/DE/BASELINE_FIGS/compute_IRF_figs.m, line 66 pr_mat_A = importdata('./BASELINE/pr_mat_A.txt');./BASELINE/pr_mat_A_theta.txttextcompute_IRF_figs.m:81
IRFS/DE/BASELINE_FIGS/compute_IRF_figs.m, line 81 pr_mat_A_thetavec = importdata('./BASELINE/pr_mat_A_theta.txt');./BASELINE/pr_mat_z.txttextcompute_IRF_figs.m:64
IRFS/DE/BASELINE_FIGS/compute_IRF_figs.m, line 64 pr_mat_z = importdata('./BASELINE/pr_mat_z.txt');./BASELINE/pr_mat_z_theta.txttextcompute_IRF_figs.m:69
IRFS/DE/BASELINE_FIGS/compute_IRF_figs.m, line 69 pr_mat_z_thetavec = importdata('./BASELINE/pr_mat_z_theta.txt');./BASELINE/spread0.txttextcompute_IRF_figs.m:67
IRFS/DE/BASELINE_FIGS/compute_IRF_figs.m, line 67 spread0=importdata('./BASELINE/spread0.txt');./BASELINE/z0.txttextcompute_IRF_figs.m:63
IRFS/DE/BASELINE_FIGS/compute_IRF_figs.m, line 63 z0 = importdata('./BASELINE/z0.txt');Dbheterosim.txttextread_diag_firms.m:144
MODEL/GE_MODEL/DE/read_diag_firms.m, line 144 Dbheterosimvec = importdata('Dbheterosim.txt');dfBsim.txttextread_diag_firms.m:138
MODEL/GE_MODEL/DE/read_diag_firms.m, line 138 dfBsim = importdata('dfBsim.txt');dfIsim.txttextread_diag_firms.m:137
MODEL/GE_MODEL/DE/read_diag_firms.m, line 137 dfIsim = importdata('dfIsim.txt');dfYsim.txttextread_diag_firms.m:136
MODEL/GE_MODEL/DE/read_diag_firms.m, line 136 dfYsim = importdata('dfYsim.txt');
first 80 of 87
2 · The file pipeline — which script writes which file that a later script reads
46 scripts, in run order for 2 master scripts and the 38 scripts they run (directly or through each other); the other 6 are not run by a master script and follow in file-name order; 40 hand-offs through 31 intermediate files; 11 files written and never read back (outputs).
2 master scripts, run in this order —
produce_results.sh before run_model_pipeline.sh:
data lineage — produce_SMM_moments.m (run by produce_results.sh) writes _GMMdatamom.txt, which compute_SE.m (run by run_model_pipeline.sh) reads-
1.
produce_results.shmaster script -
2.
EMPIRICS/CODE/replicate_empirics_STATA.dorun by produce_results.sh line 139 -
3.
EMPIRICS/CODE/step0_process_real_gdp.dorun by EMPIRICS/CODE/replicate_empirics_STATA.do line 38 reads 1 input file ·writesreal_gdp.csv→ read byproduce_SMM_moments.m -
4.
EMPIRICS/CODE/step0_read_compustat_crsp.dorun by EMPIRICS/CODE/replicate_empirics_STATA.do line 47 reads 1 input file ·writescleaned_compustat.dta→ read bystep1_link_bond_returns_compustat.do,step2_quarterly_spread.do -
5.
EMPIRICS/CODE/step0_read_crsp_ibes_link.dorun by EMPIRICS/CODE/replicate_empirics_STATA.do line 56 reads 1 input file ·writescleaned_ibes_crsp_link.dta→ read bystep2_link_compustat_bond_ibes_ticker.do -
6.
EMPIRICS/CODE/step0_read_fred_treasury.dorun by EMPIRICS/CODE/replicate_empirics_STATA.do line 65 reads 1 input file ·writescleaned_treasury.dta→ read bystep1_link_bond_returns_compustat.do,step2_quarterly_spread.do -
7.
EMPIRICS/CODE/step0_read_ibes_actuals.dorun by EMPIRICS/CODE/replicate_empirics_STATA.do line 75 reads 1 input file ·writescleaned_ibes_actual.dta→ read bystep1_unadjust_ibes_actual.do -
8.
EMPIRICS/CODE/step0_read_ibes_adjustment_factors.dorun by EMPIRICS/CODE/replicate_empirics_STATA.do line 85 reads 1 input file ·writescleaned_ibes_adj_factor.dta→ read bystep1_unadjust_and_process_ibes_guidance.do,step1_unadjust_ibes_actual.do -
9.
EMPIRICS/CODE/step0_read_ibes_guidance.dorun by EMPIRICS/CODE/replicate_empirics_STATA.do line 94 reads 1 input file ·writesraw_ibes_mgr_guidance.dta→ read bystep1_unadjust_and_process_ibes_guidance.do -
10.
EMPIRICS/CODE/step0_read_wrds_bond_CRSP_link.dorun by EMPIRICS/CODE/replicate_empirics_STATA.do line 103 reads 1 input file ·writesWRDS_bond_CRSP_link.dta→ read bystep1_link_bond_returns_compustat.do,step2_quarterly_spread.do -
11.
EMPIRICS/CODE/step0_read_wrds_bond_return.dorun by EMPIRICS/CODE/replicate_empirics_STATA.do line 112 reads 1 input file ·writesWRDS_bond_returns.dta→ read bystep1_link_bond_returns_compustat.do,step2_quarterly_spread.do -
12.
EMPIRICS/CODE/step1_link_bond_returns_compustat.dorun by EMPIRICS/CODE/replicate_empirics_STATA.do line 127 3 merges ·reads whatstep0_read_compustat_crsp.do,step0_read_fred_treasury.do,step0_read_wrds_bond_CRSP_link.do,step0_read_wrds_bond_return.dowrotewritesdefault_frac.csv→ read byproduce_SMM_moments.mwritesmerged_compustat_bond_return.dta→ read bystep2_link_compustat_bond_ibes_ticker.do -
13.
EMPIRICS/CODE/step1_unadjust_and_process_ibes_guidance.dorun by EMPIRICS/CODE/replicate_empirics_STATA.do line 136 1 merge ·reads whatstep0_read_ibes_adjustment_factors.do,step0_read_ibes_guidance.dowrotewritesunadjusted_ibes_guidance.dta→ read bystep2_link_compustat_bond_guidance.do -
14.
EMPIRICS/CODE/step1_unadjust_ibes_actual.dorun by EMPIRICS/CODE/replicate_empirics_STATA.do line 145 1 merge ·reads whatstep0_read_ibes_actuals.do,step0_read_ibes_adjustment_factors.dowrotewritescleaned_ibes_actual_unadjusted.dta→ read bystep2_link_compustat_bond_guidance.do -
15.
EMPIRICS/CODE/step2_link_compustat_bond_ibes_ticker.dorun by EMPIRICS/CODE/replicate_empirics_STATA.do line 155 1 merge ·reads whatstep0_read_crsp_ibes_link.do,step1_link_bond_returns_compustat.dowrotewritescompustat_bond_returns_ibes_ticker.dta→ read bystep2_link_compustat_bond_guidance.do -
16.
EMPIRICS/CODE/step2_link_compustat_bond_guidance.dorun by EMPIRICS/CODE/replicate_empirics_STATA.do line 168 2 merges ·reads whatstep1_unadjust_and_process_ibes_guidance.do,step1_unadjust_ibes_actual.do,step2_link_compustat_bond_ibes_ticker.dowrotewritescompustat_bond_returns_guidance.dta→ read bystep3_micro_results.do,step3_moments_prep.do,step3_industry_regs.do,step3_industry_regs_2digit.do -
17.
EMPIRICS/CODE/step2_quarterly_spread.dorun by EMPIRICS/CODE/replicate_empirics_STATA.do line 177 3 merges ·reads whatstep0_read_compustat_crsp.do,step0_read_fred_treasury.do,step0_read_wrds_bond_CRSP_link.do,step0_read_wrds_bond_return.dowrotewritesspr_by_quarter.dta→ read bystep3_quarterly_matching_series.do -
18.
EMPIRICS/CODE/step3_micro_results.dorun by EMPIRICS/CODE/replicate_empirics_STATA.do line 200 41 estimationsreads whatstep2_link_compustat_bond_guidance.dowrotewritesBvec_red.xlsx→ read byproduce_GMM_coeff.mwritesNcluster_red.xlsx→ read byproduce_GMM_coeff.mwritesNobs_red.xlsx→ read byproduce_GMM_coeff.mwritesVmat_red.xlsx→ read byproduce_GMM_coeff.m -
19.
EMPIRICS/CODE/step3_quarterly_matching_series.dorun by EMPIRICS/CODE/replicate_empirics_STATA.do line 216 reads 5 input files · 5 merges ·reads whatstep2_quarterly_spread.dowrotewritesquarterly_levels_series.csv→ read bystep3_spr_cyclicality.do,produce_crisis_spread_targets.mwrites (not read again):quarterly_matching_series.csv -
20.
EMPIRICS/CODE/step3_spr_cyclicality.dorun by EMPIRICS/CODE/replicate_empirics_STATA.do line 222reads whatstep3_quarterly_matching_series.dowrote -
21.
EMPIRICS/CODE/step3_moments_prep.dorun by EMPIRICS/CODE/replicate_empirics_STATA.do line 231 10 estimationsreads whatstep2_link_compustat_bond_guidance.dowrotewritesBvec.xlsx→ read byproduce_SMM_moments.mwritesNcluster.xlsx→ read byproduce_SMM_moments.mwritesNobs.xlsx→ read byproduce_SMM_moments.mwritesVmat.xlsx→ read byproduce_SMM_moments.mwritesspread.csv→ read byproduce_SMM_moments.m -
22.
EMPIRICS/CODE/step3_industry_regs.dorun by EMPIRICS/CODE/replicate_empirics_STATA.do line 240 11 estimationsreads whatstep2_link_compustat_bond_guidance.dowrote -
23.
EMPIRICS/CODE/step3_industry_regs_2digit.dorun by EMPIRICS/CODE/replicate_empirics_STATA.do line 247 4 estimationsreads whatstep2_link_compustat_bond_guidance.dowrote -
24.
EMPIRICS/CODE/replicate_empirics_MATLAB.mrun by produce_results.sh line 140 -
25.
EMPIRICS/CODE/produce_GMM_coeff.mrun by EMPIRICS/CODE/replicate_empirics_MATLAB.m line 20reads whatstep3_micro_results.dowrotewrites (not read again):TABLE_B2_COL_3.txt
21 more scripts
-
26.
EMPIRICS/CODE/produce_SMM_moments.mrun by EMPIRICS/CODE/replicate_empirics_MATLAB.m line 37reads whatstep0_process_real_gdp.do,step1_link_bond_returns_compustat.do,step3_moments_prep.dowrotewrites_GMMdatamom.txt→ read bycompute_SE.m,model_fit.m,compute_SE.m,model_fit.mwrites_GMMdatawgt.txt→ read bycompute_SE.m,model_fit.m,compute_SE.m,model_fit.mwrites_GMMmomcov.txt→ read bycompute_SE.m,model_fit.m,compute_SE.m,model_fit.mwrites (not read again):Table_5_DATA.txt -
27.
EMPIRICS/CODE/stationaryBB.mrun by EMPIRICS/CODE/produce_SMM_moments.m line 111 -
28.
EMPIRICS/CODE/produce_crisis_spread_targets.mrun by EMPIRICS/CODE/replicate_empirics_MATLAB.m line 51reads whatstep3_quarterly_matching_series.dowrotewrites (not read again):FIG_4_INV_TARGETS_DATA.txt,FIG_4_SPREAD_TARGETS_DATA.txt,FIG_4_TFP_TARGETS_DATA.txt -
29.
MODEL/run_model_pipeline.shmaster script -
30.
MODEL/ESTIMATION/DE/compute_SE.mrun by MODEL/run_model_pipeline.sh line 236 reads 2 input files ·reads whatproduce_SMM_moments.mwrotewrites (not read again):TABLE_4_DE.txt -
31.
MODEL/ESTIMATION/DE/model_fit.mrun by MODEL/run_model_pipeline.sh line 237 reads 4 input files ·reads whatproduce_SMM_moments.mwrotewrites (not read again):TABLE_5_DE.txt -
32.
IRFS/DE/BASELINE_FIGS/compute_IRF_figs.mrun by MODEL/run_model_pipeline.sh line 252 reads 13 input files · -
33.
MODEL/GE_MODEL/DE/read_diag_firms.mrun by MODEL/run_model_pipeline.sh line 262 reads 42 input files ·writesSTATAOUT.csv→ read byread_diag.do -
34.
MODEL/SIMULATION/DE/LONG_SIM/read_diag_firms.mreads 49 input files ·writesSTATAOUT.csv→ read byread_diag.do,read_diag_fin_disruptions.do,read_diag_macro_regs.do,read_diag_fin_disruptions.dowritesSTATAOUTfirm.csv→ read byread_firms.do -
35.
MODEL/GE_MODEL/DE/read_diag.dorun by MODEL/run_model_pipeline.sh line 265 4 estimationsreads whatread_diag_firms.m,read_diag_firms.mwrote -
36.
MODEL/GE_MODEL/DE/make_wage_R2_plot.mrun by MODEL/run_model_pipeline.sh line 268 reads 1 input file · -
37.
MODEL/SIMULATION/DE/LONG_SIM/read_diag_fin_disruptions.dorun by MODEL/run_model_pipeline.sh line 282 4 estimationsreads whatread_diag_firms.mwrote -
38.
MODEL/SIMULATION/DE/LONG_SIM/read_diag_macro_regs.dorun by MODEL/run_model_pipeline.sh line 298 3 estimationsreads whatread_diag_firms.mwrote -
39.
MODEL/SIMULATION/DE/LONG_SIM/make_fin_disruption_paths_fig.mrun by MODEL/run_model_pipeline.sh line 301 reads 2 input files · -
40.
MODEL/SIMULATION/DE/MANY_FIRMS/read_diag_firms.mreads 48 input files ·writesSTATAOUTfirm.csv→ read byread_firms.do -
41.
MODEL/SIMULATION/DE/MANY_FIRMS/read_firms.dorun by MODEL/run_model_pipeline.sh line 314 3 estimationsreads whatread_diag_firms.m,read_diag_firms.mwrote -
42.
MODEL/SIMULATION/DE/SPR_MATCH/make_crisis_bar_plot.mrun by MODEL/run_model_pipeline.sh line 324 -
43.
MODEL/ESTIMATION/RE/compute_SE.mreads 3 input files ·reads whatproduce_SMM_moments.mwrotewrites (not read again):TABLE_4_RE.txt -
44.
MODEL/ESTIMATION/RE/model_fit.mreads 4 input files ·reads whatproduce_SMM_moments.mwrotewrites (not read again):TABLE_5_RE.txt -
45.
MODEL/SIMULATION/RE/LONG_SIM/read_diag_firms.mreads 48 input files ·writesSTATAOUT.csv→ read byread_diag_fin_disruptions.dowrites (not read again):Vrat.mat -
46.
MODEL/SIMULATION/RE/LONG_SIM/read_diag_fin_disruptions.do4 estimationsreads whatread_diag_firms.m,read_diag_firms.mwrote
3 · Merges — 16 joins, 11 followed by a check of the merge result
| Joins | How | On keys | Check that follows | Where |
|---|---|---|---|---|
wrds_bond_returns ← wrds_bond_crsp_link |
join m:m (inner) | cusip |
none | step1_link_bond_returns_compustat.do:18EMPIRICS/CODE/step1_link_bond_returns_compustat.do, line 18
joinby cusip using "../TEMP/WRDS_bond_CRSP_link.dta" |
wrds_bond_returns ← cleaned_compustat |
join m:m (right) | lpermno lpermco fyear |
drop _merge |
step1_link_bond_returns_compustat.do:83EMPIRICS/CODE/step1_link_bond_returns_compustat.do, line 83
joinby lpermno lpermco fyear using "../TEMP/cleaned_compustat.dta", unmatched(using) |
wrds_bond_returns ← cleaned_treasury |
join m:m (left) | fyear |
drop _merge |
step1_link_bond_returns_compustat.do:107EMPIRICS/CODE/step1_link_bond_returns_compustat.do, line 107
joinby fyear using "../TEMP/cleaned_treasury.dta",unmatched(master) |
raw_ibes_mgr_guidance ← cleaned_ibes_adj_factor |
join m:m (inner) | ticker |
none | step1_unadjust_and_process_ibes_guidance.do:38EMPIRICS/CODE/step1_unadjust_and_process_ibes_guidance.do, line 38
joinby ticker using "../TEMP/cleaned_ibes_adj_factor.dta" |
cleaned_ibes_actual ← cleaned_ibes_adj_factor |
join m:m (inner) | ticker |
none | step1_unadjust_ibes_actual.do:24EMPIRICS/CODE/step1_unadjust_ibes_actual.do, line 24
joinby ticker using "../TEMP/cleaned_ibes_adj_factor.dta" |
merged_compustat_bond_return ← cleaned_ibes_crsp_link |
join m:m (left) | permno |
none | step2_link_compustat_bond_ibes_ticker.do:19EMPIRICS/CODE/step2_link_compustat_bond_ibes_ticker.do, line 19
joinby permno using "../TEMP/cleaned_ibes_crsp_link.dta", unmatched(master) |
compustat_bond_returns_ibes_ticker ← unadjusted_ibes_guidance |
join m:m (left) | ticker fyear |
drop _merge |
step2_link_compustat_bond_guidance.do:14EMPIRICS/CODE/step2_link_compustat_bond_guidance.do, line 14
joinby ticker fyear using "../TEMP/unadjusted_ibes_guidance.dta", unmatched(master) |
compustat_bond_returns_ibes_ticker ← cleaned_ibes_actual_unadjusted |
join m:m (left) | ticker fyear |
drop _merge |
step2_link_compustat_bond_guidance.do:18EMPIRICS/CODE/step2_link_compustat_bond_guidance.do, line 18
joinby ticker fyear using "../TEMP/cleaned_ibes_actual_unadjusted.dta", unmatched(master) |
wrds_bond_returns ← wrds_bond_crsp_link |
join m:m (inner) | cusip |
none | step2_quarterly_spread.do:15EMPIRICS/CODE/step2_quarterly_spread.do, line 15
joinby cusip using "../TEMP/WRDS_bond_CRSP_link.dta" |
wrds_bond_returns ← cleaned_compustat |
join m:m (right) | lpermno lpermco fyear |
drop _merge |
step2_quarterly_spread.do:51EMPIRICS/CODE/step2_quarterly_spread.do, line 51
joinby lpermno lpermco fyear using "../TEMP/cleaned_compustat.dta", unmatched(using) |
wrds_bond_returns ← cleaned_treasury |
join m:m (left) | fyear |
drop _merge |
step2_quarterly_spread.do:56EMPIRICS/CODE/step2_quarterly_spread.do, line 56
joinby fyear using "../TEMP/cleaned_treasury.dta",unmatched(master) |
gdp_by_quarter ← inv_by_quarter |
join m:m (outer) | quarter |
drop _merge |
step3_quarterly_matching_series.do:82EMPIRICS/CODE/step3_quarterly_matching_series.do, line 82
joinby quarter using "../TEMP/inv_by_quarter.dta", unmatched(both) |
gdp_by_quarter ← spr_by_quarter |
join m:m (outer) | quarter |
drop _merge |
step3_quarterly_matching_series.do:84EMPIRICS/CODE/step3_quarterly_matching_series.do, line 84
joinby quarter using "../TEMP/spr_by_quarter.dta", unmatched(both) |
gdp_by_quarter ← nominal_credit_by_quarter |
join m:m (outer) | quarter |
drop _merge |
step3_quarterly_matching_series.do:86EMPIRICS/CODE/step3_quarterly_matching_series.do, line 86
joinby quarter using "../TEMP/nominal_credit_by_quarter.dta", unmatched(both) |
gdp_by_quarter ← gdp_deflator_by_quarter |
join m:m (outer) | quarter |
drop _merge |
step3_quarterly_matching_series.do:88EMPIRICS/CODE/step3_quarterly_matching_series.do, line 88
joinby quarter using "../TEMP/gdp_deflator_by_quarter.dta", unmatched(both) |
gdp_by_quarter ← dtfp_by_quarter |
join m:m (outer) | quarter |
drop _merge |
step3_quarterly_matching_series.do:90EMPIRICS/CODE/step3_quarterly_matching_series.do, line 90
joinby quarter using "../TEMP/dtfp_by_quarter.dta", unmatched(both) |
4 · The sample — 76 keep/drop steps, 10 variables winsorized or trimmed
Filters, by kind
industry screens ×8
- drop if
sic>=4900&sic<5000step3_micro_results.do:18
EMPIRICS/CODE/step3_micro_results.do, line 18 drop if sic>=4900&sic<5000 - drop if
sic>=6000&sic<7000step3_micro_results.do:20
EMPIRICS/CODE/step3_micro_results.do, line 20 drop if sic>=6000&sic<7000 - drop if
sic>=4900&sic<5000step3_moments_prep.do:18
EMPIRICS/CODE/step3_moments_prep.do, line 18 drop if sic>=4900&sic<5000 - drop if
sic>=6000&sic<7000step3_moments_prep.do:20
EMPIRICS/CODE/step3_moments_prep.do, line 20 drop if sic>=6000&sic<7000 - drop if
sic>=4900&sic<5000step3_industry_regs.do:18
EMPIRICS/CODE/step3_industry_regs.do, line 18 drop if sic>=4900&sic<5000 - drop if
sic>=6000&sic<7000step3_industry_regs.do:20
EMPIRICS/CODE/step3_industry_regs.do, line 20 drop if sic>=6000&sic<7000 - drop if
sic>=4900&sic<5000step3_industry_regs_2digit.do:18
EMPIRICS/CODE/step3_industry_regs_2digit.do, line 18 drop if sic>=4900&sic<5000 - drop if
sic>=6000&sic<7000step3_industry_regs_2digit.do:20
EMPIRICS/CODE/step3_industry_regs_2digit.do, line 20 drop if sic>=6000&sic<7000
time period ×6
- keep if
datematchstep2_link_compustat_bond_ibes_ticker.do:42
EMPIRICS/CODE/step2_link_compustat_bond_ibes_ticker.do, line 42 keep if datematch - keep if
fyear<=2018step3_micro_results.do:37
EMPIRICS/CODE/step3_micro_results.do, line 37 keep if fyear<=2018 - keep if
fyear<=2018step3_moments_prep.do:37
EMPIRICS/CODE/step3_moments_prep.do, line 37 keep if fyear<=2018 - keep if
fyear>=2002step3_moments_prep.do:127
EMPIRICS/CODE/step3_moments_prep.do, line 127 keep if fyear>=2002 - keep if
fyear<=2018step3_industry_regs.do:32
EMPIRICS/CODE/step3_industry_regs.do, line 32 keep if fyear<=2018 - keep if
fyear<=2018step3_industry_regs_2digit.do:32
EMPIRICS/CODE/step3_industry_regs_2digit.do, line 32 keep if fyear<=2018
value ranges ×10
- drop if
NOBS>1step0_read_compustat_crsp.do:23
EMPIRICS/CODE/step0_read_compustat_crsp.do, line 23 drop if NOBS>1 - keep if
horz>=250&horz<=375step1_unadjust_and_process_ibes_guidance.do:30
EMPIRICS/CODE/step1_unadjust_and_process_ibes_guidance.do, line 30 keep if horz>=250&horz<=375 - keep if
typeobs>0step1_unadjust_and_process_ibes_guidance.do:65
EMPIRICS/CODE/step1_unadjust_and_process_ibes_guidance.do, line 65 keep if typeobs>0 - keep if
adj>0step1_unadjust_and_process_ibes_guidance.do:70
EMPIRICS/CODE/step1_unadjust_and_process_ibes_guidance.do, line 70 keep if adj>0 - keep if
typeobs>0step1_unadjust_ibes_actual.do:50
EMPIRICS/CODE/step1_unadjust_ibes_actual.do, line 50 keep if typeobs>0 - keep if
adj>0step1_unadjust_ibes_actual.do:55
EMPIRICS/CODE/step1_unadjust_ibes_actual.do, line 55 keep if adj>0 - drop if
NOBS>1step1_unadjust_ibes_actual.do:74
EMPIRICS/CODE/step1_unadjust_ibes_actual.do, line 74 drop if NOBS>1 - keep if
NFIRMOBS>=5step3_moments_prep.do:200
EMPIRICS/CODE/step3_moments_prep.do, line 200 keep if NFIRMOBS>=5 - first 8 of 10
category values ×13
- keep if
linkprim == "P"step0_read_compustat_crsp.do:12
EMPIRICS/CODE/step0_read_compustat_crsp.do, line 12 keep if linkprim == "P" - keep if
loc == "USA"step0_read_compustat_crsp.do:18
EMPIRICS/CODE/step0_read_compustat_crsp.do, line 18 keep if loc == "USA" - keep if
measure == "EPS"step0_read_ibes_actuals.do:14
EMPIRICS/CODE/step0_read_ibes_actuals.do, line 14 keep if measure == "EPS" - keep if
pdicity == "ANN"step0_read_ibes_actuals.do:16
EMPIRICS/CODE/step0_read_ibes_actuals.do, line 16 keep if pdicity == "ANN" - keep if
curr_act == "USD"step0_read_ibes_actuals.do:17
EMPIRICS/CODE/step0_read_ibes_actuals.do, line 17 keep if curr_act == "USD" - keep if
measure =="EPS"step0_read_ibes_guidance.do:14
EMPIRICS/CODE/step0_read_ibes_guidance.do, line 14 keep if measure =="EPS" - keep if
units =="P/S"step0_read_ibes_guidance.do:16
EMPIRICS/CODE/step0_read_ibes_guidance.do, line 16 keep if units =="P/S" - keep if
pdicity == "ANN"step0_read_ibes_guidance.do:17
EMPIRICS/CODE/step0_read_ibes_guidance.do, line 17 keep if pdicity == "ANN" - first 8 of 13
indicator subsets ×9
- keep if
priusa == 1step0_read_compustat_crsp.do:15
EMPIRICS/CODE/step0_read_compustat_crsp.do, line 15 keep if priusa == 1 - keep if
score == 1step0_read_crsp_ibes_link.do:11
EMPIRICS/CODE/step0_read_crsp_ibes_link.do, line 11 keep if score == 1 - keep if
usfirm == 1step0_read_ibes_actuals.do:15
EMPIRICS/CODE/step0_read_ibes_actuals.do, line 15 keep if usfirm == 1 - keep if
usfirm==1step0_read_ibes_adjustment_factors.do:14
EMPIRICS/CODE/step0_read_ibes_adjustment_factors.do, line 14 keep if usfirm==1 - keep if
usfirm == 1step0_read_ibes_guidance.do:15
EMPIRICS/CODE/step0_read_ibes_guidance.do, line 15 keep if usfirm == 1 - keep if
conv == 0step1_link_bond_returns_compustat.do:25
EMPIRICS/CODE/step1_link_bond_returns_compustat.do, line 25 keep if conv == 0 - keep if
NUMOBS==1step1_link_bond_returns_compustat.do:51
EMPIRICS/CODE/step1_link_bond_returns_compustat.do, line 51 keep if NUMOBS==1 - keep if
conv == 0step2_quarterly_spread.do:22
EMPIRICS/CODE/step2_quarterly_spread.do, line 22 keep if conv == 0 - first 8 of 9
row position (_n, first / last row) ×3
- keep if
seqnum==NUMOBSstep1_link_bond_returns_compustat.do:102
EMPIRICS/CODE/step1_link_bond_returns_compustat.do, line 102 keep if seqnum==NUMOBS - keep if
seqnum==1step1_unadjust_and_process_ibes_guidance.do:34
EMPIRICS/CODE/step1_unadjust_and_process_ibes_guidance.do, line 34 keep if seqnum==1 - keep if
seqnum==1step1_unadjust_ibes_actual.do:86
EMPIRICS/CODE/step1_unadjust_ibes_actual.do, line 86 keep if seqnum==1
missing values ×25
- drop if
missing(actual_value_adj)step1_unadjust_ibes_actual.do:65
EMPIRICS/CODE/step1_unadjust_ibes_actual.do, line 65 drop if missing(actual_value_adj) - drop if
NOBS>1&!missing(ticker)step2_link_compustat_bond_ibes_ticker.do:48
EMPIRICS/CODE/step2_link_compustat_bond_ibes_ticker.do, line 48 drop if NOBS>1&!missing(ticker) - drop if
ppent<=0|missing(ppent)step3_micro_results.do:31
EMPIRICS/CODE/step3_micro_results.do, line 31 drop if ppent<=0|missing(ppent) - drop if
at<=0|missing(at)step3_micro_results.do:32
EMPIRICS/CODE/step3_micro_results.do, line 32 drop if at<=0|missing(at) - drop if
emp<=0|missing(emp)step3_micro_results.do:33
EMPIRICS/CODE/step3_micro_results.do, line 33 drop if emp<=0|missing(emp) - drop if
capxv<0|missing(capxv)step3_micro_results.do:34
EMPIRICS/CODE/step3_micro_results.do, line 34 drop if capxv<0|missing(capxv) - drop if
sale<=0|missing(sale)step3_micro_results.do:35
EMPIRICS/CODE/step3_micro_results.do, line 35 drop if sale<=0|missing(sale) - drop if
ppent<=0|missing(ppent)step3_moments_prep.do:31
EMPIRICS/CODE/step3_moments_prep.do, line 31 drop if ppent<=0|missing(ppent) - first 8 of 25
time windows set by a variable — a loop or a computed date, not fixed years (rolling estimation windows, not the sample period) ×2
- keep if
bond_date >= start_date & bond_date<=end_datestep1_link_bond_returns_compustat.do:21
EMPIRICS/CODE/step1_link_bond_returns_compustat.do, line 21 keep if bond_date >= start_date & bond_date<=end_date - keep if
bond_date >= start_date & bond_date<=end_datestep2_quarterly_spread.do:18
EMPIRICS/CODE/step2_quarterly_spread.do, line 18 keep if bond_date >= start_date & bond_date<=end_date
Outliers
winsorize at 5/95
· 6 variables
pitok feprimetok fetok fcsttok itok bprimetokstep3_industry_regs_2digit.do:60
EMPIRICS/CODE/step3_industry_regs_2digit.do, line 60
winsor2 pitok feprimetok fetok fcsttok itok, cuts(5 95) replace
step3_micro_results.do:61
EMPIRICS/CODE/step3_micro_results.do, line 61
winsor2 pitok feprimetok fetok fcsttok bprimetok itok, cuts(5 95) replace
step3_moments_prep.do:63
EMPIRICS/CODE/step3_moments_prep.do, line 63
winsor2 pitok feprimetok fetok fcsttok bprimetok itok, cuts(5 95) replace
step3_industry_regs.do:60
EMPIRICS/CODE/step3_industry_regs.do, line 60
winsor2 pitok feprimetok fetok fcsttok itok, cuts(5 95) replace
winsorize at 1/99
· 4 variables
bondret spread d_spread ret_eomstep3_industry_regs_2digit.do:99
EMPIRICS/CODE/step3_industry_regs_2digit.do, line 99
winsor2 bondret spread d_spread, cuts(1 99) replace
step3_micro_results.do:100
EMPIRICS/CODE/step3_micro_results.do, line 100
winsor2 bondret spread d_spread, cuts(1 99) replace
step2_quarterly_spread.do:74
EMPIRICS/CODE/step2_quarterly_spread.do, line 74
winsor2 spread ret_eom, cuts(1 99) replace
step3_moments_prep.do:102
EMPIRICS/CODE/step3_moments_prep.do, line 102
winsor2 bondret spread d_spread, cuts(1 99) replace
Missing values
dropped ×25
step3_industry_regs.do:26
EMPIRICS/CODE/step3_industry_regs.do, line 26 drop if ppent<=0|missing(ppent)step3_industry_regs.do:27
EMPIRICS/CODE/step3_industry_regs.do, line 27 drop if at<=0|missing(at)step3_industry_regs.do:28
EMPIRICS/CODE/step3_industry_regs.do, line 28 drop if emp<=0|missing(emp)step3_industry_regs.do:29
EMPIRICS/CODE/step3_industry_regs.do, line 29 drop if capxv<0|missing(capxv)step3_industry_regs.do:30
EMPIRICS/CODE/step3_industry_regs.do, line 30 drop if sale<=0|missing(sale)step3_industry_regs.do:112
EMPIRICS/CODE/step3_industry_regs.do, line 112 keep if !missing(ind)&!missing(fyear)
common sample across variables (listwise) ×8
step3_industry_regs.do:129
EMPIRICS/CODE/step3_industry_regs.do, line 129 gen ivsamp = e(sample)step3_micro_results.do:142
EMPIRICS/CODE/step3_micro_results.do, line 142 gen TAB1SAMP = e(sample)step3_micro_results.do:190
EMPIRICS/CODE/step3_micro_results.do, line 190 gen CONS_SAMP = e(sample)step3_micro_results.do:464
EMPIRICS/CODE/step3_micro_results.do, line 464 qui: ivreghdfe bondret (fetok = l.itok ) if !missing(d_spread)&!missing(d_itok), absorb( fyear) cluster(gvkey)step3_micro_results.do:465
EMPIRICS/CODE/step3_micro_results.do, line 465 gen ivsamp = e(sample)step3_micro_results.do:577
EMPIRICS/CODE/step3_micro_results.do, line 577 qui: ivreghdfe bondret (fetok = l.itok ) if hy==0&!missing(d_spread)&!missing(d_itok), absorb( fyear) cluster(gvkey)
5 · Key variables — what enters the models, and where the code builds it
Standard measures computed here:
Capital Expenditure ()
itok step3_industry_regs.do:50
EMPIRICS/CODE/step3_industry_regs.do, line 50
gen itok = capxv/ppent
| Variable | Used in models as | Built by |
|---|---|---|
fetok |
outcome in 11, endogenous in 11, regressor in 4 | fetok = fe/ppent (gen) step3_micro_results.do:47EMPIRICS/CODE/step3_micro_results.do, line 47
gen fetok = fe/ppent fetok = fe/ppent (gen) step3_moments_prep.do:48EMPIRICS/CODE/step3_moments_prep.do, line 48
gen fetok = fe/ppent fetok = fe/ppent (gen) step3_industry_regs.do:47EMPIRICS/CODE/step3_industry_regs.do, line 47
gen fetok = fe/ppent +2 more statements set it |
feprimetok |
outcome in 16 | feprimetok = f.fe/ppent (gen) step3_micro_results.do:48EMPIRICS/CODE/step3_micro_results.do, line 48
gen feprimetok = f.fe/ppent feprimetok = f.fe/ppent (gen) step3_moments_prep.do:49EMPIRICS/CODE/step3_moments_prep.do, line 49
gen feprimetok = f.fe/ppent feprimetok = f.fe/ppent (gen) step3_industry_regs.do:48EMPIRICS/CODE/step3_industry_regs.do, line 48
gen feprimetok = f.fe/ppent +2 more statements set it |
bondret |
outcome in 13 | bondret = ret_gvkey_q4 (gen) step3_micro_results.do:96EMPIRICS/CODE/step3_micro_results.do, line 96
gen bondret = ret_gvkey_q4 bondret = ret_gvkey_q4 (gen) step3_moments_prep.do:98EMPIRICS/CODE/step3_moments_prep.do, line 98
gen bondret = ret_gvkey_q4 bondret = ret_gvkey_q4 (gen) step3_industry_regs.do:95EMPIRICS/CODE/step3_industry_regs.do, line 95
gen bondret = ret_gvkey_q4 +1 more statements set it |
ditok |
outcome in 7, regressor in 1 | ditok = itok - l.itok (gen) step3_micro_results.do:240EMPIRICS/CODE/step3_micro_results.do, line 240
gen ditok = itok - l.itok ditok = itok - l.itok (gen) step3_moments_prep.do:139EMPIRICS/CODE/step3_moments_prep.do, line 139
gen ditok = itok - l.itok ditok = itok - l.itok (gen) step3_industry_regs.do:119EMPIRICS/CODE/step3_industry_regs.do, line 119
gen ditok = itok - l.itok +2 more statements set it |
d_itok |
outcome in 5 | d_itok = itok-l.itok (gen) step3_micro_results.do:462EMPIRICS/CODE/step3_micro_results.do, line 462
gen d_itok = itok-l.itok |
logw |
outcome in 4 | logw = log(wsim) (gen) read_diag.do:64MODEL/GE_MODEL/DE/read_diag.do, line 64
gen logw = log(wsim) |
Agrowth |
outcome in 2 | Agrowth = logA - l.logA (gen) read_diag.do:52MODEL/GE_MODEL/DE/read_diag.do, line 52
gen Agrowth = logA - l.logA Agrowth = logA - l.logA (gen) read_diag_fin_disruptions.do:53MODEL/SIMULATION/DE/LONG_SIM/read_diag_fin_disruptions.do, line 53
gen Agrowth = logA - l.logA Agrowth = logA - l.logA (gen) read_diag_macro_regs.do:55MODEL/SIMULATION/DE/LONG_SIM/read_diag_macro_regs.do, line 55
gen Agrowth = logA - l.logA +1 more statements set it |
Igrowth |
outcome in 2 | Igrowth = logI - l.logI (gen) read_diag.do:45MODEL/GE_MODEL/DE/read_diag.do, line 45
gen Igrowth = logI - l.logI Igrowth = logI - l.logI (gen) read_diag_fin_disruptions.do:46MODEL/SIMULATION/DE/LONG_SIM/read_diag_fin_disruptions.do, line 46
gen Igrowth = logI - l.logI Igrowth = logI - l.logI (gen) read_diag_macro_regs.do:48MODEL/SIMULATION/DE/LONG_SIM/read_diag_macro_regs.do, line 48
gen Igrowth = logI - l.logI +1 more statements set it |
agglevgrowth |
outcome in 2 | agglevgrowth = agglev - l.agglev (gen) read_diag.do:56MODEL/GE_MODEL/DE/read_diag.do, line 56
gen agglevgrowth = agglev - l.agglev agglevgrowth = agglev - l.agglev (gen) read_diag_fin_disruptions.do:57MODEL/SIMULATION/DE/LONG_SIM/read_diag_fin_disruptions.do, line 57
gen agglevgrowth = agglev - l.agglev agglevgrowth = agglev - l.agglev (gen) read_diag_macro_regs.do:59MODEL/SIMULATION/DE/LONG_SIM/read_diag_macro_regs.do, line 59
gen agglevgrowth = agglev - l.agglev +1 more statements set it |
d2bprimetok |
outcome in 2 | d2bprimetok = bprimetok - l2.bprimetok (gen) step3_micro_results.do:395EMPIRICS/CODE/step3_micro_results.do, line 395
gen d2bprimetok = bprimetok - l2.bprimetok d2bprimetok = bprimetok - l2.bprimetok (gen) step3_moments_prep.do:143EMPIRICS/CODE/step3_moments_prep.do, line 143
gen d2bprimetok = bprimetok - l2.bprimetok |
d2feprimetok |
outcome in 2 | d2feprimetok = feprimetok - l2.feprimetok (gen) step3_micro_results.do:387EMPIRICS/CODE/step3_micro_results.do, line 387
gen d2feprimetok = feprimetok - l2.feprimetok d2feprimetok = feprimetok - l2.feprimetok (gen) step3_moments_prep.do:134EMPIRICS/CODE/step3_moments_prep.do, line 134
gen d2feprimetok = feprimetok - l2.feprimetok |
d2itok |
outcome in 2 | d2itok = itok - l2.itok (gen) step3_micro_results.do:392EMPIRICS/CODE/step3_micro_results.do, line 392
gen d2itok = itok - l2.itok d2itok = itok - l2.itok (gen) step3_moments_prep.do:140EMPIRICS/CODE/step3_moments_prep.do, line 140
gen d2itok = itok - l2.itok |
dbprimetok |
outcome in 2 | dbprimetok = bprimetok - l.bprimetok (gen) step3_micro_results.do:394EMPIRICS/CODE/step3_micro_results.do, line 394
gen dbprimetok = bprimetok - l.bprimetok dbprimetok = bprimetok - l.bprimetok (gen) step3_moments_prep.do:142EMPIRICS/CODE/step3_moments_prep.do, line 142
gen dbprimetok = bprimetok - l.bprimetok dbprimetok = (f.debt-debt)/kfirm (gen) read_firms.do:53MODEL/SIMULATION/DE/MANY_FIRMS/read_firms.do, line 53
gen dbprimetok = (f.debt-debt)/kfirm |
dfeprimetok |
outcome in 2 | dfeprimetok = feprimetok - l.feprimetok (gen) step3_micro_results.do:386EMPIRICS/CODE/step3_micro_results.do, line 386
gen dfeprimetok = feprimetok - l.feprimetok dfeprimetok = feprimetok - l.feprimetok (gen) step3_moments_prep.do:133EMPIRICS/CODE/step3_moments_prep.do, line 133
gen dfeprimetok = feprimetok - l.feprimetok |
spreadgrowth |
outcome in 2 | spreadgrowth = spreadsim - l.spreadsim (gen) read_diag.do:43MODEL/GE_MODEL/DE/read_diag.do, line 43
gen spreadgrowth = spreadsim - l.spreadsim spreadgrowth = spreadsim - l.spreadsim (gen) read_diag_fin_disruptions.do:44MODEL/SIMULATION/DE/LONG_SIM/read_diag_fin_disruptions.do, line 44
gen spreadgrowth = spreadsim - l.spreadsim spreadgrowth = spreadsim - l.spreadsim (gen) read_diag_macro_regs.do:46MODEL/SIMULATION/DE/LONG_SIM/read_diag_macro_regs.do, line 46
gen spreadgrowth = spreadsim - l.spreadsim +1 more statements set it |
FEtoK |
outcome in 1 | FEtoK = FEsim/Ksim (gen) read_diag_macro_regs.do:73MODEL/SIMULATION/DE/LONG_SIM/read_diag_macro_regs.do, line 73
gen FEtoK = FEsim/Ksim |
d2pitok |
outcome in 1 | d2pitok = pitok - l2.pitok (gen) step3_micro_results.do:390EMPIRICS/CODE/step3_micro_results.do, line 390
gen d2pitok = pitok - l2.pitok d2pitok = pitok - l2.pitok (gen) step3_moments_prep.do:137EMPIRICS/CODE/step3_moments_prep.do, line 137
gen d2pitok = pitok - l2.pitok |
dItoK |
outcome in 1 | dItoK = ItoK - l.ItoK (gen) read_diag_macro_regs.do:75MODEL/SIMULATION/DE/LONG_SIM/read_diag_macro_regs.do, line 75
gen dItoK = ItoK - l.ItoK |
dpitok |
outcome in 1 | dpitok = pitok - l.pitok (gen) step3_micro_results.do:389EMPIRICS/CODE/step3_micro_results.do, line 389
gen dpitok = pitok - l.pitok dpitok = pitok - l.pitok (gen) step3_moments_prep.do:136EMPIRICS/CODE/step3_moments_prep.do, line 136
gen dpitok = pitok - l.pitok |
retbond |
outcome in 1 | retbond = (1+dfpos*(recovery-1))/l.qfirm (gen) read_firms.do:62MODEL/SIMULATION/DE/MANY_FIRMS/read_firms.do, line 62
gen retbond = (1+dfpos*(recovery-1))/l.qfirm |
retbondsim |
outcome in 1 | retbondsim = v11 (gen) read_diag.do:28MODEL/GE_MODEL/DE/read_diag.do, line 28
gen retbondsim = v11 retbondsim = v11 (gen) read_diag_fin_disruptions.do:28MODEL/SIMULATION/DE/LONG_SIM/read_diag_fin_disruptions.do, line 28
gen retbondsim = v11 retbondsim = v11 (gen) read_diag_macro_regs.do:30MODEL/SIMULATION/DE/LONG_SIM/read_diag_macro_regs.do, line 30
gen retbondsim = v11 +1 more statements set it |
itok |
instrument in 6, regressor in 12 | itok = capxv/ppent (gen) step3_micro_results.do:50EMPIRICS/CODE/step3_micro_results.do, line 50
gen itok = capxv/ppent itok = capxv/ppent (gen) step3_moments_prep.do:51EMPIRICS/CODE/step3_moments_prep.do, line 51
gen itok = capxv/ppent itok = capxv/ppent (gen) step3_industry_regs.do:50EMPIRICS/CODE/step3_industry_regs.do, line 50
gen itok = capxv/ppent +2 more statements set it |
litok |
instrument in 5, regressor in 9 | litok = l.itok (gen) step3_micro_results.do:474EMPIRICS/CODE/step3_micro_results.do, line 474
gen litok = l.itok litok = l.itok (gen) step3_industry_regs.do:122EMPIRICS/CODE/step3_industry_regs.do, line 122
gen litok = l.itok litok = l.itok (gen) step3_industry_regs_2digit.do:123EMPIRICS/CODE/step3_industry_regs_2digit.do, line 123
gen litok = l.itok +1 more statements set it |
crisis |
regressor in 24 | crisis = Igrowth<r(p10) (gen) read_diag_fin_disruptions.do:70MODEL/SIMULATION/DE/LONG_SIM/read_diag_fin_disruptions.do, line 70
gen crisis = Igrowth<r(p10) crisis = Igrowth<r(p10) (gen) read_diag_fin_disruptions.do:70MODEL/SIMULATION/RE/LONG_SIM/read_diag_fin_disruptions.do, line 70
gen crisis = Igrowth<r(p10) crisis = crisis & spreadgrowth>r(p90) (replace) read_diag_fin_disruptions.do:73MODEL/SIMULATION/DE/LONG_SIM/read_diag_fin_disruptions.do, line 73
replace crisis = crisis & spreadgrowth>r(p90) +1 more statements set it |
pitok |
regressor in 13 | pitok = ib/ppent (gen) step3_micro_results.do:49EMPIRICS/CODE/step3_micro_results.do, line 49
gen pitok = ib/ppent pitok = ib/ppent (gen) step3_moments_prep.do:50EMPIRICS/CODE/step3_moments_prep.do, line 50
gen pitok = ib/ppent pitok = ib/ppent (gen) step3_industry_regs.do:49EMPIRICS/CODE/step3_industry_regs.do, line 49
gen pitok = ib/ppent +2 more statements set it |
Asimpos |
regressor in 10 | Asimpos = v15 (gen) read_diag.do:34MODEL/GE_MODEL/DE/read_diag.do, line 34
gen Asimpos = v15 |
fetokhat |
regressor in 9 | fetokhat = predict(xb) (predict) step3_micro_results.do:530EMPIRICS/CODE/step3_micro_results.do, line 530
predict fetokhat, xb fetokhat = predict(xb) (predict) step3_micro_results.do:584EMPIRICS/CODE/step3_micro_results.do, line 584
predict fetokhat, xb fetokhat = predict(xb) (predict) step3_industry_regs.do:134EMPIRICS/CODE/step3_industry_regs.do, line 134
predict fetokhat, xb +3 more statements set it |
lspread |
regressor in 8 | lspread = l.spread (gen) step3_industry_regs.do:123EMPIRICS/CODE/step3_industry_regs.do, line 123
gen lspread = l.spread lspread = l.spread (gen) step3_industry_regs_2digit.do:124EMPIRICS/CODE/step3_industry_regs_2digit.do, line 124
gen lspread = l.spread |
FEtoKhat |
regressor in 2 | FEtoKhat = predict(xb) (predict) read_diag_macro_regs.do:87MODEL/SIMULATION/DE/LONG_SIM/read_diag_macro_regs.do, line 87
predict FEtoKhat,xb |
PItoK |
regressor in 2 | PItoK = Pisim/Ksim (gen) read_diag_macro_regs.do:76MODEL/SIMULATION/DE/LONG_SIM/read_diag_macro_regs.do, line 76
gen PItoK = Pisim/Ksim |
spreadsim |
regressor in 2 | spreadsim = v6 (gen) read_diag.do:21MODEL/GE_MODEL/DE/read_diag.do, line 21
gen spreadsim = v6 spreadsim = v6 (gen) read_diag_fin_disruptions.do:21MODEL/SIMULATION/DE/LONG_SIM/read_diag_fin_disruptions.do, line 21
gen spreadsim = v6 spreadsim = v6 (gen) read_diag_macro_regs.do:23MODEL/SIMULATION/DE/LONG_SIM/read_diag_macro_regs.do, line 23
gen spreadsim = v6 +1 more statements set it |
bprimetok |
regressor in 1 | bprimetok = f.totdebt/at (gen) step3_micro_results.do:59EMPIRICS/CODE/step3_micro_results.do, line 59
gen bprimetok = f.totdebt/at bprimetok = f.totdebt/at (gen) step3_moments_prep.do:60EMPIRICS/CODE/step3_moments_prep.do, line 60
gen bprimetok = f.totdebt/at bprimetok = f.debt/kfirm (gen) read_firms.do:49MODEL/SIMULATION/DE/MANY_FIRMS/read_firms.do, line 49
gen bprimetok = f.debt/kfirm |
f_fcsttok |
regressor in 1 | f_fcsttok = f.fcsttok (gen) step3_micro_results.do:117EMPIRICS/CODE/step3_micro_results.do, line 117
gen f_fcsttok = f.fcsttok f_fcsttok = f.fcsttok (gen) step3_moments_prep.do:115EMPIRICS/CODE/step3_moments_prep.do, line 115
gen f_fcsttok = f.fcsttok |
l2ditok |
regressor in 1 | l2ditok = l2.ditok (gen) step3_micro_results.do:242EMPIRICS/CODE/step3_micro_results.do, line 242
gen l2ditok = l2.ditok |
lItoK |
regressor in 1 | lItoK = l.ItoK (gen) read_diag_macro_regs.do:80MODEL/SIMULATION/DE/LONG_SIM/read_diag_macro_regs.do, line 80
gen lItoK = l.ItoK |
lditok |
regressor in 1 | lditok = l.ditok (gen) step3_micro_results.do:241EMPIRICS/CODE/step3_micro_results.do, line 241
gen lditok = l.ditok |
6 · Models, by the table or figure they feed — 84 estimations, 40 traced into 11 exhibits
Table 1
· 4 estimations → TABLE_1.txt
| Command | Outcome | Regressors | Fixed effects | Standard errors | Where |
|---|---|---|---|---|---|
reghdfepanel fe |
feprimetok |
pitok
|
gvkey, fyear | cluster: gvkey | step3_micro_results.do:135EMPIRICS/CODE/step3_micro_results.do, line 135
eststo: reghdfe feprimetok pitok if fe_samp, absorb(gvkey fyear) cluster(gvkey) written at step3_micro_results.do:178 |
reghdfepanel fe |
feprimetok |
itok
|
gvkey, fyear | cluster: gvkey | step3_micro_results.do:144EMPIRICS/CODE/step3_micro_results.do, line 144
eststo: reghdfe feprimetok itok if fe_samp, absorb(gvkey fyear) cluster(gvkey) written at step3_micro_results.do:178 |
reghdfepanel fe |
feprimetok |
bprimetok
|
gvkey, fyear | cluster: gvkey | step3_micro_results.do:152EMPIRICS/CODE/step3_micro_results.do, line 152
eststo: reghdfe feprimetok bprimetok if fe_samp, absorb(gvkey fyear) cluster(gvkey) written at step3_micro_results.do:178 |
reghdfepanel fe |
feprimetok |
f_fcsttok
|
gvkey, fyear | cluster: gvkey | step3_micro_results.do:160EMPIRICS/CODE/step3_micro_results.do, line 160
eststo: reghdfe feprimetok f_fcsttok if fe_samp, absorb(gvkey fyear) cluster(gvkey) written at step3_micro_results.do:178 |
Table 2
· 3 estimations → TABLE_2.txt
| Command | Outcome | Regressors | Fixed effects | Standard errors | Where |
|---|---|---|---|---|---|
ivreghdfepanel fe |
fetok |
litok
|
fyear | cluster: gvkey | step3_micro_results.do:534EMPIRICS/CODE/step3_micro_results.do, line 534
eststo: qui: ivreghdfe fetok litok if ivsamp, absorb( fyear) cluster(gvkey) written at step3_micro_results.do:556 |
ivreghdfeiv |
bondret |
endogenous:
fetok instruments: l.itok |
fyear | cluster: gvkey | step3_micro_results.do:542EMPIRICS/CODE/step3_micro_results.do, line 542
eststo: qui: ivreghdfe bondret (fetok = l.itok ) if ivsamp, absorb( fyear) cluster(gvkey) written at step3_micro_results.do:556 |
ivreghdfepanel fe |
d_itok |
fetokhat pitok
|
fyear | cluster: gvkey | step3_micro_results.do:549EMPIRICS/CODE/step3_micro_results.do, line 549
eststo: qui: ivreghdfe d_itok fetokhat pitok if ivsamp, absorb(fyear) cluster(gvkey) written at step3_micro_results.do:556 |
Table 8
· 3 estimations → TABLE_8_PAN_A.txt
| Command | Outcome | Regressors | Fixed effects | Standard errors | Where |
|---|---|---|---|---|---|
reghdfepanel fe |
fetok |
litok
|
ind | cluster: ind | step3_industry_regs.do:131EMPIRICS/CODE/step3_industry_regs.do, line 131
eststo: qui: reghdfe fetok litok if ivsamp,absorb(ind) cluster(ind) written at step3_industry_regs.do:146 |
reghdfepanel fe |
bondret |
fetokhat lspread pitok
|
ind | cluster: ind | step3_industry_regs.do:136EMPIRICS/CODE/step3_industry_regs.do, line 136
eststo: qui: reghdfe bondret fetokhat lspread pitok if ivsamp ,absorb(ind) cluster(ind) written at step3_industry_regs.do:146 |
reghdfepanel fe |
ditok |
fetokhat lspread pitok
|
ind | cluster: ind | step3_industry_regs.do:139EMPIRICS/CODE/step3_industry_regs.do, line 139
eststo: qui: reghdfe ditok fetokhat lspread pitok if ivsamp ,absorb(ind) cluster(ind) written at step3_industry_regs.do:146 |
Table B2
· 2 estimations → TABLE_B2_COLS_1TO2.txt
| Command | Outcome | Regressors | Fixed effects | Standard errors | Where |
|---|---|---|---|---|---|
reghdfepanel fe |
feprimetok |
itok
|
fyear | cluster: gvkey | step3_micro_results.do:193EMPIRICS/CODE/step3_micro_results.do, line 193
eststo: reghdfe feprimetok itok if CONS_SAMP, absorb(fyear) cluster(gvkey) written at step3_micro_results.do:209 |
reghdfepanel fe |
feprimetok |
itok
|
gvkey, fyear | cluster: gvkey | step3_micro_results.do:201EMPIRICS/CODE/step3_micro_results.do, line 201
eststo: reghdfe feprimetok itok if fe_samp, absorb(gvkey fyear) cluster(gvkey) written at step3_micro_results.do:209 |
Table B3
· 6 estimations → TABLE_B3.txt
| Command | Outcome | Regressors | Fixed effects | Standard errors | Where |
|---|---|---|---|---|---|
reghdfepanel fe |
feprimetok |
itok
|
gvkey, fyear | cluster: gvkey | step3_micro_results.do:326EMPIRICS/CODE/step3_micro_results.do, line 326
eststo: reghdfe feprimetok itok if fe_samp, absorb(gvkey fyear) cluster(gvkey) written at step3_micro_results.do:374 |
reghdfepanel fe |
feprimetok |
itok
|
gvkey, fyear | cluster: gvkey | step3_micro_results.do:339EMPIRICS/CODE/step3_micro_results.do, line 339
eststo: reghdfe feprimetok itok if fe_samp&hy==0, absorb(gvkey fyear) cluster(gvkey) written at step3_micro_results.do:374 |
reghdfepanel fe |
feprimetok |
itok
|
gvkey, fyear | cluster: gvkey | step3_micro_results.do:346EMPIRICS/CODE/step3_micro_results.do, line 346
eststo: reghdfe feprimetok itok if fe_samp&NOBS_NONMISS>=5, absorb(gvkey fyear) cluster(gvkey) written at step3_micro_results.do:374 |
reghdfepanel fe |
feprimetok |
itok
|
gvkey, fyear | cluster: gvkey | step3_micro_results.do:353EMPIRICS/CODE/step3_micro_results.do, line 353
eststo: reghdfe feprimetok itok if fe_samp&fyear>=2009, absorb(gvkey fyear) cluster(gvkey) written at step3_micro_results.do:374 |
reghdfepanel fe |
feprimetok |
itok
|
gvkey, fyear | cluster: gvkey | step3_micro_results.do:360EMPIRICS/CODE/step3_micro_results.do, line 360
eststo: reghdfe feprimetok itok if fe_samp&itok_high==1, absorb(gvkey fyear) cluster(gvkey) written at step3_micro_results.do:374 |
reghdfepanel fe |
feprimetok |
itok
|
gvkey, fyear | cluster: gvkey | step3_micro_results.do:367EMPIRICS/CODE/step3_micro_results.do, line 367
eststo: reghdfe feprimetok itok if fe_samp&itok_high==0, absorb(gvkey fyear) cluster(gvkey) written at step3_micro_results.do:374 |
Table B4
· 3 estimations → TABLE_B4.txt
| Command | Outcome | Regressors | Fixed effects | Standard errors | Where |
|---|---|---|---|---|---|
reghdfepanel fe |
feprimetok |
ditok
|
fyear | cluster: gvkey | step3_micro_results.do:249EMPIRICS/CODE/step3_micro_results.do, line 249
eststo: reghdfe feprimetok ditok if fe_samp, absorb(fyear) cluster(gvkey) written at step3_micro_results.do:272 |
reghdfepanel fe |
feprimetok |
lditok
|
fyear | cluster: gvkey | step3_micro_results.do:256EMPIRICS/CODE/step3_micro_results.do, line 256
eststo: reghdfe feprimetok lditok if fe_samp, absorb(fyear) cluster(gvkey) written at step3_micro_results.do:272 |
reghdfepanel fe |
feprimetok |
l2ditok
|
fyear | cluster: gvkey | step3_micro_results.do:263EMPIRICS/CODE/step3_micro_results.do, line 263
eststo: reghdfe feprimetok l2ditok if fe_samp, absorb(fyear) cluster(gvkey) written at step3_micro_results.do:272 |
Table B5
· 5 estimations → TABLE_B5.txt
| Command | Outcome | Regressors | Fixed effects | Standard errors | Where |
|---|---|---|---|---|---|
ivreghdfepanel fe |
fetok |
litok
|
fyear | cluster: gvkey | step3_micro_results.do:588EMPIRICS/CODE/step3_micro_results.do, line 588
eststo: qui: ivreghdfe fetok litok if ivsamp, absorb( fyear) cluster(gvkey) written at step3_micro_results.do:624 |
ivreghdfepanel fe |
bondret |
fetok
|
fyear | cluster: gvkey | step3_micro_results.do:596EMPIRICS/CODE/step3_micro_results.do, line 596
eststo: qui: ivreghdfe bondret fetok if ivsamp, absorb( fyear) cluster(gvkey) written at step3_micro_results.do:624 |
ivreghdfeiv |
bondret |
endogenous:
fetok instruments: l.itok |
fyear | cluster: gvkey | step3_micro_results.do:603EMPIRICS/CODE/step3_micro_results.do, line 603
eststo: qui: ivreghdfe bondret (fetok = l.itok ) if ivsamp, absorb( fyear) cluster(gvkey) written at step3_micro_results.do:624 |
ivreghdfepanel fe |
d_itok |
fetok pitok
|
fyear | cluster: gvkey | step3_micro_results.do:610EMPIRICS/CODE/step3_micro_results.do, line 610
eststo: qui: ivreghdfe d_itok fetok pitok if ivsamp, absorb(fyear) cluster(gvkey) written at step3_micro_results.do:624 |
ivreghdfepanel fe |
d_itok |
fetokhat pitok
|
fyear | cluster: gvkey | step3_micro_results.do:617EMPIRICS/CODE/step3_micro_results.do, line 617
eststo: qui: ivreghdfe d_itok fetokhat pitok if ivsamp, absorb(fyear) cluster(gvkey) written at step3_micro_results.do:624 |
Table B6
· 5 estimations → TABLE_B6.txt
| Command | Outcome | Regressors | Fixed effects | Standard errors | Where |
|---|---|---|---|---|---|
ivreghdfepanel fe |
fetok |
litok
|
fyear | cluster: gvkey | step3_micro_results.do:476EMPIRICS/CODE/step3_micro_results.do, line 476
eststo: qui: ivreghdfe fetok litok if ivsamp, absorb(fyear) cluster(gvkey) written at step3_micro_results.do:514 |
ivreghdfepanel fe |
bondret |
fetok
|
fyear | cluster: gvkey | step3_micro_results.do:485EMPIRICS/CODE/step3_micro_results.do, line 485
eststo: qui: ivreghdfe bondret fetok if ivsamp, absorb(fyear) cluster(gvkey) written at step3_micro_results.do:514 |
ivreghdfeiv |
bondret |
endogenous:
fetok instruments: l.itok |
fyear | cluster: gvkey | step3_micro_results.do:492EMPIRICS/CODE/step3_micro_results.do, line 492
eststo: qui: ivreghdfe bondret (fetok = l.itok ) if ivsamp, absorb( fyear) cluster(gvkey) written at step3_micro_results.do:514 |
ivreghdfepanel fe |
d_itok |
fetok
|
fyear | cluster: gvkey | step3_micro_results.do:499EMPIRICS/CODE/step3_micro_results.do, line 499
eststo: qui: ivreghdfe d_itok fetok if ivsamp, absorb( fyear) cluster(gvkey) written at step3_micro_results.do:514 |
ivreghdfeiv |
d_itok |
endogenous:
fetok instruments: l.itok |
fyear | cluster: gvkey | step3_micro_results.do:506EMPIRICS/CODE/step3_micro_results.do, line 506
eststo: qui: ivreghdfe d_itok (fetok = l.itok ) if ivsamp, absorb(fyear) cluster(gvkey) written at step3_micro_results.do:514 |
Table B7
· 3 estimations → TABLE_B7.txt
| Command | Outcome | Regressors | Fixed effects | Standard errors | Where |
|---|---|---|---|---|---|
reghdfepanel fe |
fetok |
litok
|
ind | cluster: ind | step3_industry_regs_2digit.do:133EMPIRICS/CODE/step3_industry_regs_2digit.do, line 133
eststo: qui: reghdfe fetok litok if ivsamp,absorb(ind) cluster(ind) written at step3_industry_regs_2digit.do:147 |
reghdfepanel fe |
bondret |
fetokhat lspread pitok
|
ind | cluster: ind | step3_industry_regs_2digit.do:138EMPIRICS/CODE/step3_industry_regs_2digit.do, line 138
eststo: qui: reghdfe bondret fetokhat lspread pitok if ivsamp ,absorb(ind) cluster(ind) written at step3_industry_regs_2digit.do:147 |
reghdfepanel fe |
ditok |
fetokhat lspread pitok
|
ind | cluster: ind | step3_industry_regs_2digit.do:141EMPIRICS/CODE/step3_industry_regs_2digit.do, line 141
eststo: qui: reghdfe ditok fetokhat lspread pitok if ivsamp ,absorb(ind) cluster(ind) written at step3_industry_regs_2digit.do:147 |
Table B8
· 3 estimations → TABLE_B8.txt
| Command | Outcome | Regressors | Fixed effects | Standard errors | Where |
|---|---|---|---|---|---|
ivreghdfepanel fe |
fetok |
litok
|
ind | cluster: ind | step3_industry_regs.do:162EMPIRICS/CODE/step3_industry_regs.do, line 162
eststo: qui: ivreghdfe fetok litok if ivsamp , absorb(ind) cluster(ind) written at step3_industry_regs.do:172 |
ivreghdfeiv |
bondret |
endogenous:
fetok instruments: litok |
ind | cluster: ind | step3_industry_regs.do:166EMPIRICS/CODE/step3_industry_regs.do, line 166
eststo: qui: ivreghdfe bondret (fetok = litok) if ivsamp , absorb(ind) cluster(ind) written at step3_industry_regs.do:172 |
ivreghdfeiv |
ditok |
endogenous:
fetok instruments: litok |
ind | cluster: ind | step3_industry_regs.do:169EMPIRICS/CODE/step3_industry_regs.do, line 169
eststo: qui: ivreghdfe ditok (fetok = litok) if ivsamp , absorb(ind) cluster(ind) written at step3_industry_regs.do:172 |
Table B9
· 3 estimations → TABLE_B9.txt
| Command | Outcome | Regressors | Fixed effects | Standard errors | Where |
|---|---|---|---|---|---|
reghdfepanel fe |
fetok |
litok
|
— | cluster: ind | step3_industry_regs.do:191EMPIRICS/CODE/step3_industry_regs.do, line 191
eststo: qui: reghdfe fetok litok if ivsamp , noabsorb cluster(ind) written at step3_industry_regs.do:205 |
reghdfepanel fe |
bondret |
fetokhat lspread pitok
|
— | cluster: ind | step3_industry_regs.do:195EMPIRICS/CODE/step3_industry_regs.do, line 195
eststo: qui: reghdfe bondret fetokhat lspread pitok if ivsamp ,noabsorb cluster(ind) written at step3_industry_regs.do:205 |
reghdfepanel fe |
ditok |
fetokhat lspread pitok
|
— | cluster: ind | step3_industry_regs.do:198EMPIRICS/CODE/step3_industry_regs.do, line 198
eststo: qui: reghdfe ditok fetokhat lspread pitok if ivsamp ,noabsorb cluster(ind) written at step3_industry_regs.do:205 |
Estimations not traced to a table or figure · 44
| Command | Outcome | Regressors | Fixed effects | Standard errors | Where |
|---|---|---|---|---|---|
reghdfepanel fe |
`var' |
gvkey, fyear | cluster: gvkey | step3_micro_results.do:121EMPIRICS/CODE/step3_micro_results.do, line 121
qui: reghdfe `var' if momsamp,absorb(gvkey fyear) cluster(gvkey) residuals(res_`var') run 10× in a loop (var=d_sale; var=d_spread; var=bondret…)
|
|
reghdfepanel fe |
feprimetok |
itok
|
gvkey, fyear | cluster: gvkey | step3_micro_results.do:189EMPIRICS/CODE/step3_micro_results.do, line 189
qui: reghdfe feprimetok itok if fe_samp, absorb(gvkey fyear) cluster(gvkey) |
reghdfepanel fe |
dfeprimetok |
fyear | default | step3_micro_results.do:397EMPIRICS/CODE/step3_micro_results.do, line 397
reghdfe dfeprimetok, absorb(fyear) res(dfeprimetok_r) |
|
reghdfepanel fe |
d2feprimetok |
fyear | default | step3_micro_results.do:399EMPIRICS/CODE/step3_micro_results.do, line 399
reghdfe d2feprimetok, absorb(fyear) res(d2feprimetok_r) |
|
reghdfepanel fe |
ditok |
fyear | default | step3_micro_results.do:401EMPIRICS/CODE/step3_micro_results.do, line 401
reghdfe ditok, absorb(fyear) res(ditok_r) |
|
reghdfepanel fe |
d2itok |
fyear | default | step3_micro_results.do:402EMPIRICS/CODE/step3_micro_results.do, line 402
reghdfe d2itok, absorb(fyear) res(d2itok_r) |
|
reghdfepanel fe |
dbprimetok |
fyear | default | step3_micro_results.do:404EMPIRICS/CODE/step3_micro_results.do, line 404
reghdfe dbprimetok, absorb(fyear) res(dbprimetok_r) |
|
reghdfepanel fe |
d2bprimetok |
fyear | default | step3_micro_results.do:405EMPIRICS/CODE/step3_micro_results.do, line 405
reghdfe d2bprimetok, absorb(fyear) res(d2bprimetok_r) |
|
regols |
mom`varnum' |
— | default | step3_micro_results.do:426EMPIRICS/CODE/step3_micro_results.do, line 426
qui: reg mom`varnum' if NOBS_NONMISS>=5 run 9× in a loop (varnum=1; varnum=2; varnum=3…)
|
|
ivreghdfeiv |
bondret |
endogenous:
fetok instruments: l.itok |
fyear | cluster: gvkey | step3_micro_results.do:464EMPIRICS/CODE/step3_micro_results.do, line 464
qui: ivreghdfe bondret (fetok = l.itok ) if !missing(d_spread)&!missing(d_itok), absorb( fyear) cluster(gvkey) |
ivreghdfepanel fe |
fetok |
l.itok
|
fyear | cluster: gvkey | step3_micro_results.do:529EMPIRICS/CODE/step3_micro_results.do, line 529
ivreghdfe fetok l.itok if ivsamp, absorb(fyear) cluster(gvkey) |
ivreghdfeiv |
bondret |
endogenous:
fetok instruments: l.itok |
fyear | cluster: gvkey | step3_micro_results.do:577EMPIRICS/CODE/step3_micro_results.do, line 577
qui: ivreghdfe bondret (fetok = l.itok ) if hy==0&!missing(d_spread)&!missing(d_itok), absorb( fyear) cluster(gvkey) |
ivreghdfepanel fe |
fetok |
l.itok
|
fyear | cluster: gvkey | step3_micro_results.do:583EMPIRICS/CODE/step3_micro_results.do, line 583
ivreghdfe fetok l.itok if ivsamp, absorb(fyear) cluster(gvkey) |
reghdfepanel fe |
`var' |
gvkey, fyear | cluster: gvkey | step3_moments_prep.do:119EMPIRICS/CODE/step3_moments_prep.do, line 119
qui: reghdfe `var' if momsamp,absorb(gvkey fyear) cluster(gvkey) residuals(res_`var') run 10× in a loop (var=d_sale; var=d_spread; var=bondret…)
|
|
reghdfepanel fe |
dfeprimetok |
fyear | default | step3_moments_prep.do:145EMPIRICS/CODE/step3_moments_prep.do, line 145
reghdfe dfeprimetok, absorb(fyear) res(dfeprimetok_r) |
|
reghdfepanel fe |
d2feprimetok |
fyear | default | step3_moments_prep.do:146EMPIRICS/CODE/step3_moments_prep.do, line 146
reghdfe d2feprimetok, absorb(fyear) res(d2feprimetok_r) |
|
reghdfepanel fe |
dpitok |
fyear | default | step3_moments_prep.do:148EMPIRICS/CODE/step3_moments_prep.do, line 148
reghdfe dpitok, absorb(fyear) res(dpitok_r) |
|
reghdfepanel fe |
d2pitok |
fyear | default | step3_moments_prep.do:149EMPIRICS/CODE/step3_moments_prep.do, line 149
reghdfe d2pitok, absorb(fyear) res(d2pitok_r) |
|
reghdfepanel fe |
ditok |
fyear | default | step3_moments_prep.do:151EMPIRICS/CODE/step3_moments_prep.do, line 151
reghdfe ditok, absorb(fyear) res(ditok_r) |
|
reghdfepanel fe |
d2itok |
fyear | default | step3_moments_prep.do:152EMPIRICS/CODE/step3_moments_prep.do, line 152
reghdfe d2itok, absorb(fyear) res(d2itok_r) |
|
reghdfepanel fe |
dbprimetok |
fyear | default | step3_moments_prep.do:154EMPIRICS/CODE/step3_moments_prep.do, line 154
reghdfe dbprimetok, absorb(fyear) res(dbprimetok_r) |
|
reghdfepanel fe |
d2bprimetok |
fyear | default | step3_moments_prep.do:155EMPIRICS/CODE/step3_moments_prep.do, line 155
reghdfe d2bprimetok, absorb(fyear) res(d2bprimetok_r) |
|
regols |
mom`varnum' |
— | default | step3_moments_prep.do:207EMPIRICS/CODE/step3_moments_prep.do, line 207
qui: reg mom`varnum' |
|
ivreghdfeiv |
bondret |
lspread pitok
endogenous:
fetok instruments: litok |
ind | default | step3_industry_regs.do:128EMPIRICS/CODE/step3_industry_regs.do, line 128
qui: ivreghdfe bondret (fetok = litok) lspread pitok, absorb(ind) |
reghdfepanel fe |
fetok |
litok
|
— | cluster: ind | step3_industry_regs.do:187EMPIRICS/CODE/step3_industry_regs.do, line 187
qui: reghdfe fetok litok if ivsamp,noabsorb cluster(ind) |
ivreghdfeiv |
bondret |
lspread pitok
endogenous:
fetok instruments: litok |
ind | default | step3_industry_regs_2digit.do:130EMPIRICS/CODE/step3_industry_regs_2digit.do, line 130
qui: ivreghdfe bondret (fetok = litok) lspread pitok, absorb(ind) |
regols |
logw |
i.Asimpos
|
— | default | read_diag.do:66MODEL/GE_MODEL/DE/read_diag.do, line 66
qui: reg logw i.Asimpos |
regols |
logw |
i.Asimpos##l.Asimpos
|
— | default | read_diag.do:69MODEL/GE_MODEL/DE/read_diag.do, line 69
qui: reg logw i.Asimpos##l.Asimpos |
regols |
logw |
i.Asimpos##i.l.Asimpos##i.l2.Asimpos
|
— | default | read_diag.do:72MODEL/GE_MODEL/DE/read_diag.do, line 72
qui: reg logw i.Asimpos##i.l.Asimpos##i.l2.Asimpos |
regols |
logw |
i.Asimpos##i.l.Asimpos##i.l2.Asimpos##i.l3.Asimpos
|
— | default | read_diag.do:75MODEL/GE_MODEL/DE/read_diag.do, line 75
qui: reg logw i.Asimpos##i.l.Asimpos##i.l2.Asimpos##i.l3.Asimpos |
regols |
Agrowth |
crisis l.crisis l2.crisis
|
— | default | read_diag_fin_disruptions.do:78MODEL/SIMULATION/DE/LONG_SIM/read_diag_fin_disruptions.do, line 78
reg Agrowth crisis l.crisis l2.crisis, nocons |
regols |
agglevgrowth |
crisis l.crisis l2.crisis
|
— | default | read_diag_fin_disruptions.do:90MODEL/SIMULATION/DE/LONG_SIM/read_diag_fin_disruptions.do, line 90
reg agglevgrowth crisis l.crisis l2.crisis, nocons |
regols |
Igrowth |
crisis l.crisis l2.crisis
|
— | default | read_diag_fin_disruptions.do:102MODEL/SIMULATION/DE/LONG_SIM/read_diag_fin_disruptions.do, line 102
reg Igrowth crisis l.crisis l2.crisis, nocons |
regols |
spreadgrowth |
crisis l.crisis l2.crisis
|
— | default | read_diag_fin_disruptions.do:114MODEL/SIMULATION/DE/LONG_SIM/read_diag_fin_disruptions.do, line 114
reg spreadgrowth crisis l.crisis l2.crisis, nocons |
reghdfepanel fe |
FEtoK |
lItoK
|
indnum | cluster: indnum | read_diag_macro_regs.do:84MODEL/SIMULATION/DE/LONG_SIM/read_diag_macro_regs.do, line 84
qui: eststo: reghdfe FEtoK lItoK, absorb(indnum) cluster(indnum) |
reghdfepanel fe |
retbondsim |
FEtoKhat l.spreadsim PItoK
|
indnum | cluster: indnum | read_diag_macro_regs.do:92MODEL/SIMULATION/DE/LONG_SIM/read_diag_macro_regs.do, line 92
qui: eststo: reghdfe retbondsim FEtoKhat l.spreadsim PItoK,absorb(indnum) cluster(indnum) |
reghdfepanel fe |
dItoK |
FEtoKhat l.spreadsim PItoK
|
indnum | cluster: indnum | read_diag_macro_regs.do:93MODEL/SIMULATION/DE/LONG_SIM/read_diag_macro_regs.do, line 93
qui: eststo: reghdfe dItoK FEtoKhat l.spreadsim PItoK,absorb(indnum) cluster(indnum) |
ivreghdfepanel fe |
fetok |
litok
|
time | cluster: firm | read_firms.do:84MODEL/SIMULATION/DE/MANY_FIRMS/read_firms.do, line 84
qui: ivreghdfe fetok litok if ivsamp , absorb(time) cluster(firm) |
ivreghdfeiv |
retbond |
endogenous:
fetok instruments: litok |
time | cluster: firm | read_firms.do:89MODEL/SIMULATION/DE/MANY_FIRMS/read_firms.do, line 89
qui: eststo: ivreghdfe retbond (fetok = litok) if ivsamp, absorb(time) cluster(firm) first savefirst |
ivreghdfepanel fe |
ditok |
fetokhat pitok
|
time | cluster: firm | read_firms.do:91MODEL/SIMULATION/DE/MANY_FIRMS/read_firms.do, line 91
qui: eststo: ivreghdfe ditok fetokhat pitok if ivsamp , absorb(time) cluster(firm) |
Tables and figures the code writes:
· · Table 6 · Table 6 · Table 6
FIN_DISRUPTIONS_PATHS.txt read_diag_fin_disruptions.do:135
MODEL/SIMULATION/RE/LONG_SIM/read_diag_fin_disruptions.do, line 135
file open myfile using "FIN_DISRUPTIONS_PATHS.txt", write replace
R2_VALUES.txt read_diag.do:80
MODEL/GE_MODEL/DE/read_diag.do, line 80
file open myfile using "R2_VALUES.txt", write replace
TABLE_6.txt step3_spr_cyclicality.do:28
EMPIRICS/CODE/step3_spr_cyclicality.do, line 28
file open myfile using "../OUTPUT/TABLE_6.txt", write replace
TABLE_6_RE.txt read_diag_fin_disruptions.do:177
MODEL/SIMULATION/RE/LONG_SIM/read_diag_fin_disruptions.do, line 177
file open fh using "`outfile'", write replace
as we read it (macros filled in / loop expanded):
file open fh using "../../../OUTPUT/TABLE_6_RE.txt", write replace
TABLE_6_DE.txt read_diag_fin_disruptions.do:176
MODEL/SIMULATION/DE/LONG_SIM/read_diag_fin_disruptions.do, line 176
file open fh using "`outfile'", write replace
as we read it (macros filled in / loop expanded):
file open fh using "../../../OUTPUT/TABLE_6_DE.txt", write replace
7 · Figures: how each is drawn — 12 figures in the code (command, layers, options, the file it is saved to)
line 10 · bar 2
| command | layers | variables | options | saved as | where |
|---|---|---|---|---|---|
twowayline
|
line |
y feprimetok_std, itok_std
x fyear
|
ytitle Percent · legend position(6) |
Figure B1FIG_B1.pdf |
step3_micro_results.do:299EMPIRICS/CODE/step3_micro_results.do, line 299
twoway line feprimetok_std itok_std fyear if fyear>=2001&fyear<=2017, ytitle("Percent") legend(position(6)) |
plotline
|
line + line |
y 100*BASELINE_IRF(:,1), 100*RAT_BASELINE_IRF(:,1), 0*BASELINE_IRF(:,1), 100*BASELINE_IRF(:,2), 100*RAT_BASELINE_IRF(:,2)
x IRFlabels
|
title TFP | Investment · xtitle Periods Since Shock | Periods Since Shock · ytitle Percent Deviation · panels 2×2 · legend 'DE Model', 'RE Model', 'location', 'northeast' |
Figure 1FIG_1.pdf |
compute_IRF_figs.m:270IRFS/DE/BASELINE_FIGS/compute_IRF_figs.m, line 270
figure; |
plotline
|
line |
y IRF_NONLIN_TAB(:,2), RAT_IRF_NONLIN_TAB(:,2), 0*IRF_NONLIN_TAB(:,2)
x IRF_NONLIN_TAB(:,1), RAT_IRF_NONLIN_TAB(:,1)
|
title Investment Response · xtitle Initial Conditions: Multiples of \sigma_A · ytitle Percent · legend 'DE Model', 'RE Model', 'location', 'northeast' |
Figure 2FIG_2.pdf |
compute_IRF_figs.m:297IRFS/DE/BASELINE_FIGS/compute_IRF_figs.m, line 297
figure; |
plotline
|
line |
y IRF_NONLIN_TAB(:,2), RAT_IRF_NONLIN_TAB(:,2), DE_W_RE_PRICING_IRF_NONLIN_TAB(:,2), 0*IRF_NONLIN_TAB(:,2)
x IRF_NONLIN_TAB(:,1), RAT_IRF_NONLIN_TAB(:,1), DE_W_RE_PRICING_IRF_NONLIN_TAB(:,1)
|
title Investment Response · xtitle Initial Conditions: Multiples of \sigma_A · ytitle Percent · legend 'DE Model', 'RE Model', 'DE Firm Model', 'location', 'northeast' |
Figure A2FIG_A2.pdf |
compute_IRF_figs.m:370IRFS/DE/BASELINE_FIGS/compute_IRF_figs.m, line 370
figure; |
plotline
|
line |
y IRF_NONLIN_TAB(:,2), RAT_IRF_NONLIN_TAB(:,2), DE_W_RE_MPRICING_IRF_NONLIN_TAB(:,2), 0*IRF_NONLIN_TAB(:,2)
x IRF_NONLIN_TAB(:,1), RAT_IRF_NONLIN_TAB(:,1), DE_W_RE_MPRICING_IRF_NONLIN_TAB(:,1)
|
title Investment Response · xtitle Initial Conditions: Multiples of \sigma_A · ytitle Percent · legend 'DE Model', 'RE Model', 'RE Firm Price Model', 'location', 'northeast' |
Figure A3FIG_A3.pdf |
compute_IRF_figs.m:446IRFS/DE/BASELINE_FIGS/compute_IRF_figs.m, line 446
figure; |
plotline
|
line |
y IRF_NONLIN_TAB(:,2), RAT_IRF_NONLIN_TAB(:,2), DE_W_NODSHIFT_IRF_NONLIN_TAB(:,2), 0*IRF_NONLIN_TAB(:,2)
x IRF_NONLIN_TAB(:,1), RAT_IRF_NONLIN_TAB(:,1), DE_W_NODSHIFT_IRF_NONLIN_TAB(:,1)
|
title Investment Response · xtitle Initial Conditions: Multiples of \sigma_A · ytitle Percent · legend 'DE Model', 'RE Model', 'DE Model, No Dist.', 'location', 'northeast' |
Figure A4FIG_A4.pdf |
compute_IRF_figs.m:525IRFS/DE/BASELINE_FIGS/compute_IRF_figs.m, line 525
figure; |
plotline
|
line |
y DE_GE_IRF_NONLIN_TAB(:,2), RE_GE_IRF_NONLIN_TAB(:,2), 0*DE_GE_IRF_NONLIN_TAB(:,2)
x DE_GE_IRF_NONLIN_TAB(:,1), RE_GE_IRF_NONLIN_TAB(:,1)
|
title Investment Response · xtitle Initial Conditions: Multiples of \sigma_A · ytitle Percent · legend 'DE Model', 'RE Model', 'location', 'northeast' |
Figure A6FIG_A6.pdf |
compute_IRF_figs.m:655IRFS/DE/BASELINE_FIGS/compute_IRF_figs.m, line 655
figure; |
plotline
|
line |
y ROBUST_NONLIN_TAB(:,2)
x ROBUST_NONLIN_TAB(:,1)
|
title Investment Response · xtitle Initial Conditions: Multiples of \sigma_A · ytitle Percent · legend LEGEND_NAME_LIST, 'location', 'eastoutside' |
Figure A7FIG_A7.pdf |
compute_IRF_figs.m:769IRFS/DE/BASELINE_FIGS/compute_IRF_figs.m, line 769
figure; |
barbar
|
bar |
y R2vec
x [0;1;2;3]
|
title Forecast Accuracy · xtitle Number of Productivity Lags · ytitle Wage Rule R^2 |
Figure A5FIG_A5.pdf |
make_wage_R2_plot.m:14MODEL/GE_MODEL/DE/make_wage_R2_plot.m, line 14
figure; |
plotline
|
line + line + line + line |
y CRISIS_LEVEL(1,:), 0*CRISIS_PER, CRISIS_LEVEL(2,:), CRISIS_LEVEL(3,:), CRISIS_LEVEL(4,:)
x CRISIS_PER
|
title Productivity | Leverage | Investment | Spread · xtitle Period | Period | Period | Period · ytitle Percent | Percent | Percent | Percentage Points · panels 2×2 · legend 'DE Model', 'RE Model', 'location', 'northwest' |
Figure 3FIG_3.pdf |
make_fin_disruption_paths_fig.m:23MODEL/SIMULATION/DE/LONG_SIM/make_fin_disruption_paths_fig.m, line 23
figure; |
plotline
|
line |
y squeeze(Vtheta(3,3,1,3,:,18)), squeeze(Vtheta(3,3,3,3,:,18)), squeeze(Vtheta(3,3,5,3,:,18)), squeeze(Vrat(3,3,5,3,:,18))
x k0
|
xtitle Capital k · ytitle Perceived Firm Value · legend 'DE, Good News', 'DE, Medium News', 'DE, Bad News', 'RE, Any News', 'Location', 'northwest' |
Figure A1FIG_A1.pdf |
read_diag_firms.m:146MODEL/SIMULATION/DE/LONG_SIM/read_diag_firms.m, line 146
figure; |
barbar
|
bar + bar + bar + bar |
y [data_inv de_inv re_inv], [data_pif de_pif re_pif], [data_spr de_spr re_spr], [data_tfp de_tfp re_tfp]
x Xlabels_2by2
|
title Investment | Profit Forecast | Spread | TFP · ytitle Percent Growth | Percent Growth | P.P. Change | Percent Growth · panels 2×2 |
Figure 4FIG_4.pdf |
make_crisis_bar_plot.m:36MODEL/SIMULATION/DE/SPR_MATCH/make_crisis_bar_plot.m, line 36
figure; |