Replication package for "International Trade Finance and Learning Dynamics"

Published: 15 May 2026| Version 2 | DOI: 10.17632/mtpm69tx6g.2
Contributors:
David Kohn, Emiliano Luttini, Michal Szkup, Shengxing Zhang

Description

REPLICATION PACKAGE: "International Trade Finance and Learning Dynamics" Authors: David Kohn, Emiliano Luttini, Michal Szkup, Shengxing Zhang. The materials are split into two independent components that together reproduce every quantitative result in the paper. 1. code_paper_final/ (MATLAB). Reproduces Figures 3-11 and Tables 5 and 7, and generates a simulated firm-year panel (166,556 firms x 30 years) used as input by Package 2. Entry point: KLSZ_master_file.m, which controls binary flags for each section. The folder contains the solver, transition, and SMM routines at the root, plus: Experiments/ -- steady-state and shock drivers (foreign- and domestic-cost shocks under five risk regimes, plus delta=1 and mu=1 counterfactuals) Figures/ -- figure-generation scripts Tables/ -- model_table_5.m, model_table_7.m Output/Figures/ -- Figure_3 through Figure_11 panel PDFs Output/Tables/ -- Table_5.xlsx, Table_7.xlsx, and six simulated panels (counterparty_belief, demand_belief, oa_status, export_status, productivity, spell_status) Requirements: MATLAB R2023b+ with Parallel Computing, Optimization, and Statistics and Machine Learning toolboxes. To run, set MATLAB's working directory to the package root and execute KLSZ_master_file. See README.md. 2. Data_Replication/ (Stata). Reproduces Tables 1-4 (Section 2), Tables 5-8 (Section 4), and Tables A1-A5 (Appendix). Master script: src/do/00_main.do, which calls 01-03 (build yearly and daily customs panels and the F29 firm-year panel), 04 (ingests Package 1's CSVs and builds MergeSimData.dta), then 05-07 (estimate regressions and write LaTeX tables to out/<version>/{section_2,section_4,appendix}/). Two modes via the data_type global: "bc" -- real Chilean customs (DUS) and tax (F29) microdata from the Central Bank's PYTRFN database (DSN: MSSQL_DPM_DS02_INNO). Authorized access only; reproduces the paper's point estimates exactly. "mock" -- synthetic panel with the same schema and filters. Fixed random seeds; reproduces every script and table but not the published numbers. Data access: the firm-level microdata cannot be redistributed under the agreement with the Central Bank of Chile. Requirements: Stata, plus SSC packages reghdfe, estout, distinct, listtex, ftools, timeit, require. The six simulation CSVs from Package 1 are shipped inside each Data_Replication subfolder's dat/ so Package 2 runs without first executing Package 1. Mapping: Figures 3-11 -> Package 1 Tables 1-4 -> Package 2 (05_section_2.do) Tables 5, 7 -> Package 1 (Tables/model_table_*.m) Tables 6, 8 -> both: simulation from Package 1 -> regressions in Package 2 (06_section_4.do) Tables A1-A5 -> Package 2 (07_appendix.do) Each package ships a README and has been verified to run end-to-end from a clean install.

Files

Institutions

Categories

Economics, International Trade, Trade Finance

Licence