## ANNEX 1. GRAVITY MODEL, DATA, AND ESTIMATION

## Source details

**Canonical URL:** [ANNEX 1. GRAVITY MODEL, DATA, AND ESTIMATION](https://www.imf.org/-/media/files/publications/weo/2019/april/english/ch4annex.pdf)

## Other formats

- [Markdown version](/-/media/files/publications/weo/2019/april/english/ch4annex.pdf.md)
- [Structured JSON version](/-/media/files/publications/weo/2019/april/english/ch4annex.pdf.json)

---

### Model specification and estimation choices
- Aggregate multiplicative gravity representation for gross exports X_ijt with core regressors:
  - Exporter gross output Y_it, importer gross expenditure E_jt, world gross output Y_wt = ∑Y_it.
- Trade cost components: physical distance, common language, common colonial history, border, FTA_ijt dummy, bilateral tariffs τ_ijt (goods only).
- Multilateral resistance terms included: outward MRT_out_it and inward MRT_in_jt.
- Home-bias dummy SM_ij (intra‑national trade = 1) interacted with geographic variables; services dummy interacts with non-tariff cost variables.
- Functional and estimation choices:
  - σ is set to 3 in baseline (robust to σ = 2).
  - Baseline constraints: β1 = β2 = 1; MRT coefficients constrained equal (β12 = β13).
  - Alternative specifications: partially unconstrained (MRT unconstrained), fully unconstrained.
  - Estimator: pseudo Poisson maximum likelihood (PPML) to include zero trade flows and account for heteroscedasticity.
  - Robustness: aggregate vs sectoral regressions, inclusion of NTMs, country-pair fixed effects, cross-section estimates at five-year horizons.

### Multilateral resistance: two-step construction and predicted trade costs
- First-step MRT proxy: bilateral GDP-weighted distance (Wei (1996) style):
  - MRT_it = (∑ (Y_jt / Y_wt) ⋅ Distance_ij^(1−σ) _j )^(1/(1−σ)), with σ = 3.
- Predicted bilateral trade costs T̂_ijt built from estimated coefficients on tariffs and other cost components:
  - T̂_ijt = exp{ −[ estimated cost component linear index ]/(1−σ) }.
- Final MRTs constructed using predicted trade costs:
  - MRT_out_it = (∑ (Y_jt / Y_wt) ⋅ T̂_ijt^(1−σ) _j )^(1/(1−σ))
  - MRT_in_jt = (∑ (Y_it / Y_wt) ⋅ T̂_jit^(1−σ) _i )^(1/(1−σ))
- Note: because of Y_wt weighting, countries with low world output shares have negligible effects on MRTs and bilateral exports.

### Data sources and construction
- Trade datasets:
  - OECD TiVA 2016: ISIC 3, 34 sectors, 63 countries, 1995-2011.
  - OECD TiVA 2018: ISIC 4, 34 sectors, 63 countries, 2005-2015.
  - Databases combined by splicing 2016 forward from 2006 using change in global GDP shares from 2018 TiVA.
  - Final sector count: 33 sectors (two sectors combined).
  - Intra-national trade constructed = gross production − exports; negative constructed values at sector level set to zero.
  - Country-sector gross expenditure built from OECD input-output tables.
  - Alternative importer expenditure measure in robustness: GDP plus imports from IMF WEO.
  - World gross production = sum of all country-sector gross output observations from TiVA.
- Trade cost and auxiliary data:
  - Tariffs: WITS, aggregated to sector level with trade-weighted averaging; tariffs set to zero for all service sectors.
  - Other trade-cost variables: CEPII.
  - Non-tariff measures (NTMs): UNCTAD TRAINS database; many missing sector-level NTMs treated as zero.

### Results — sectoral and country-level estimation (selected coefficients and fit)
- Estimation frame: sectoral gravity regression on 5-year average panels; constrained baseline and alternative specifications reported.
- Selected baseline sector-level coefficient estimates (Table 1, column (1) baseline, constrained, distance-MRT):
  - LN(Distance_ij)*(1−SM_ij)*(Non-Service): -1.081*** (0.0607)
  - LN(Distance_ij)*SM_ij*(Non-Service): -1.828*** (0.0888)
  - LN(Distance_ij)*(1−SM_ij)*(Service): -1.176*** (0.0600)
  - LN(Distance_ij)*SM_ij*(Service): -1.818*** (0.0928)
  - LN(1 + Tariff_ijt): -1.918*** (0.410)
  - LN(World Gross Output_T): -0.952*** (0.0585)
  - SM_ij (intra-national dummy): 6.665*** (0.625)
  - LN(MRT_distance_it): 0.932*** (0.0426)
  - LN(MRT_distance_jt): 0.932*** (0.0426)
  - Observations: 475,567
  - R-squared: 0.947
- Selected robustness estimates (Table 1, column (2) predicted-cost MRT):
  - LN(1 + Tariff_ijt): -1.769*** (0.397)
  - LN(World Gross Output_T): -1.005*** (0.0273)
  - SM_ij: 7.471*** (0.532)
  - LN(MRT_cost_it): 1.020*** (0.0184)
  - LN(MRT_cost_jt): 1.020*** (0.0184)
  - Observations: 474,933
  - R-squared: 0.962
- Cross-section sectoral estimates by period (Table 2) — examples for LN(1 + Tariff_ijt):
  - 1995: -0.0246 (0.406)
  - 2000: -2.900*** (0.674)
  - 2005: -3.789*** (0.544)
  - 2010: -1.951*** (0.598)
  - 2015: -1.440*** (0.479)
  - Observations by period: 1995: 87,436; 2000: 58,414; 2005: 68,353; 2010: 81,076; 2015: 62,373.
  - R-squared range: 0.959–0.969.
- Country-level (5-year average panel) selected estimates (Table 3):
  - LN(1+Tariff_ijt): -5.397*** (1.189), -5.359*** (1.138), -4.776*** (1.136), -4.207*** (0.538), -4.562*** (1.050) across specifications.
  - LN(MRT_distance_it), LN(MRT_distance_jt): 0.919*** (0.0694)
  - SM_ij: 6.722*** to 7.554*** depending on specification.
  - Observations (country-level): ~15,560
  - R-squared up to 1.000 with country-pair fixed effects.
- Trade-balance fit — sector level (Table 4, 5-year average panel):
  - Predicted Bilateral Trade Balance coefficient (constrained, MRT-distance): 0.938*** (0.244); Observations: 15,876; R-squared: 0.235.
  - Predicted Bilateral Trade Balance coefficient (constrained, MRT-cost): 1.053*** (0.214); R-squared: 0.288.
  - Period-specific instability noted (e.g., 2010 coefficient -0.0945 (0.235)).
  - Fit improves for largest bilateral balances (R-squared up to 0.535 in some periods).
- Trade-balance fit — country level (Table 5, 5-year average panel):
  - Predicted trade balance (constrained, MRT-distance): 0.799*** (0.207); Observations: 15,282; R-squared: 0.260.
  - Predicted trade balance (constrained, MRT-cost): 0.972*** (0.186); R-squared: 0.314.
  - Predicted trade balance with country-pair fixed effects (constrained): 1.001*** (0.0286); R-squared: 0.931.
  - Unconstrained specifications can yield larger coefficients (e.g., 2.287*** (0.304)) but mixed fit.
- Interpretation:
  - Tariffs have a negative and significant impact on gross bilateral exports; elasticity broadly consistent with σ = 3 assumption.
  - Inclusion of NTMs decreases the estimated tariff impact only very minorly, indicating NTMs have a separate and important impact on trade.

### Predicting bilateral trade balances and decomposition methodology
- Construction approach:
  - Bilateral imports constructed by inverting exporter estimates (column (2) of Table 1) to importer perspective to obtain predicted bilateral trade balances at aggregate or sectoral level.
  - Regression of actual bilateral trade balances on predicted values: TB_ijt = α + β TB̂_ijt + ε_ijt.
  - Gravity model explains gross exports well; explains levels of bilateral trade balances less well but explains changes (differences) in bilateral trade balances effectively.
- Approximation for change in sectoral trade balance:
  - ΔTB_ijst ≈ Δln(X_ijst) ⋅ X_ijst−1 − Δln(X_jist) ⋅ X_jist−1.
  - Predicted contributions use estimated coefficients and normalize predicted Δln of regressors by initial (t−1) bilateral exports/imports (initial values are actual).
- Decomposed contribution terms included explicitly:
  - Domestic net-supply, net-demand, world output term, multilateral costs, bilateral costs, FTAs, NTMs, and sectoral composition contributions.
  - Sectoral shares used: Y_ist = s_ist^Y ⋅ Y_it and E_jst = s_jst^E ⋅ E_jt.
  - Aggregate contributions obtained by summing sectoral contributions across s.
- Empirical decomposition results:
  - Figures A1–A3 document contributions to changes in bilateral trade balances since 1995 at sector and country levels; NTMs contribute negligibly to most bilateral trade balances.
  - Gravity model explains changes in bilateral trade balances well; levels improve substantially with country-pair fixed effects and for largest bilateral balances.

### Key methodological notes and robustness
- PPML estimation central given prevalence of zero trade flows and heteroscedasticity.
- MRT proxies: initial GDP-weighted-distance proxies (σ = 3) used as first-step; predicted-cost MRTs derived from estimated trade-cost coefficients; results robust across MRT constructions.
- Constrained baseline retained for theoretical appeal despite some unconstrained estimates showing β̂1 and β̂2 < 1 (but ~0.8 when using only international trade observations).
- Country-pair fixed effects capture bilateral time-invariant trade costs and substantially improve trade-balance level fit.
- Robustness exercises:
  - Use of GDP plus imports as importer-expenditure measure to capture global value chain effects.
  - Inclusion of NTMs (many missing assumed zero).
  - Cross-section estimates at five-year horizons.
  - Comparisons between sectoral and aggregate specifications.

*Source: ch4annex - ANNEX 1. GRAVITY MODEL, DATA, AND ESTIMATION (April 2019 World Economic Outlook).*

### ANNEX 2. DERIVATION OF RELATION BETWEEN BILATERAL AND AGGREGATE TRADE BALANCES

### Gravity framework, definitions, and MRT identities
- Gravity equation for nominal exports:
  - X_{ij} = Y_i E_j / Y_w (τ_{ij} Π_i / P_j)^{1−σ}
- Definitions:
  - Y_i, Y_w: production in country i and world.
  - E_j: total spending of country j.
  - σ: aggregate trade elasticity.
  - MRTs:
    - Π_i = [∑_j θ_j (τ_{ij} / P_j)^{1−σ}]^{1/(1−σ)}
    - P_j = [∑_i θ_i (τ_{ij} / Π_i)^{1−σ}]^{1/(1−σ)}
  - θ_i = y_i / y_w.
- Empirical note: chapter avoids country fixed effects and uses MRT proxies; short-term analysis treats output shares as fairly stable.

### Derivation linking bilateral and aggregate trade balances
- With Y proxied by GDP and E_j = Y_j − TB_j, and assuming symmetric trade costs τ_{ij} = τ_{ji} ⇒ Π_i = P_i, the gravity equation rewrites as:
  - X_{ij} / (Y_i Y_j / Y_W) = m_{ij} (1 − TB_j / Y_j)
  - m_{ij} is a bilateral trade intensity (trade bias) function of bilateral trade costs and MRTs.
- Under symmetric trade costs, m_{ij} = m_{ji}.
- Scaled bilateral trade balance identity:
  - TB_{ij} / (Y_i Y_j / Y_W) = (X_{ij} − X_{ji}) / (Y_i Y_j / Y_W) = m_{ij} (TB_i / Y_i − TB_j / Y_j)
- Empirical implementation:
  - m_{ij} estimated by substituting predicted bilateral exports X̂_{ij} from the gravity equation into the identity.
  - Any trade balance-to-GDP ratio can be decomposed into its EBA determinants.
  - Example application: Box 2 computes an average trade intensity between the United States and China by deriving m_{ij} as an unobservable residual from 1997 to 2014 and averaging.

### Analytical implications and empirical remarks
- The identity links bilateral trade balances to aggregate trade balance‑to‑GDP ratios scaled by bilateral trade intensity m_{ij}.
- Short-term analysis treating output shares as exogenous implies changes in bilateral balances reflect changes in bilateral trade costs and MRTs.
- Practical estimation:
  - MRT approximations rely on output shares being close to spending shares; approximation error small for empirically relevant aggregate imbalances.
  - Regression strategy avoids country fixed effects and uses MRT proxies to identify trade intensities.

*Source: Annex 2. Derivation of Relation Between Bilateral and Aggregate Trade Balances (ch4annex).*

### ANNEX 1. GRAVITY MODEL, DATA, AND ESTIMATION _____________________ 1

### ANNEX 1. GRAVITY MODEL, DATA, AND ESTIMATION

### Contents and Structure
- Main sections listed:
  - A. Predicting Trade Balances
- Related annexes and appendices referenced within the PDF:
  - ANNEX 2. DERIVATION OF RELATION BETWEEN BILATERAL AND AGGREGATE TRADE BALANCES
  - ANNEX 3. TARIFF SPILLOVERS: TECHNICAL AND DATA APPENDICES
    - A. Existing Literature
    - B. Calculation of Tariff Measures
    - C. Regression Model
    - D. Results
- Supporting materials enumerated:
  - REFERENCES
  - FIGURES
    - A1. Contributions to Changes in Bilateral Trade Balance Since 1995, Sector Level, Largest Bilateral Trade Balances
    - A2. Contributions to Changes in Bilateral Trade Balance Since 1995, Sector Level with NTMs
    - A3. Contributions to Changes in Bilateral Trade Balance Since 1995, Country-Level
  - TABLES
    - 1. Gravity Model: Sector Level, 5-year Average Panel
    - 2. Gravity Model: Sector Level, Cross-Section
    - 3. Gravity Model: Country Level, 5-year Average Panel
    - 4. Trade Balance Fit: Sector Level
    - 5. Trade Balance Fit: Country Level, 5-year Average Panel
    - 6. Trade Balance and current account EBA regressions
    - 7. Tariff Effects on Economic Variables
    - 8. Tariff Effects on Different Real Variables; normalized with C-Y and Ind-FE
    - 9. Robustness to Lag-order, Effect on VA

### Scope and Focus (as indicated by headings)
- Predicting trade balances via a gravity model framework at both sector and country levels.
- Deriving the relation between bilateral and aggregate trade balances.
- Technical and data appendices focused on tariff spillovers, including:
  - Literature review (Existing Literature).
  - Construction and calculation of tariff measures (Calculation of Tariff Measures).
  - Specification of regression models used (Regression Model).
  - Empirical results from regressions and robustness checks (Results).

### Empirical Materials and Analytical Tools (as listed)
- Gravity-model estimations reported in multiple table formats:
  - Sector-level 5-year average panel and cross-section results.
  - Country-level 5-year average panel results.
- Trade-balance fit diagnostics at sector and country levels.
- Regressions linking trade balances and current accounts (EBA regressions).
- Analysis of tariff effects on economic and real variables, including robustness checks and normalization methods.
- Figures documenting contributions to changes in bilateral trade balances since 1995, at sector and country levels, and with non-tariff measures (NTMs).

### Publication and Pagination Metadata (from source header)
- Document part of April 2019 World Economic Outlook.
- International Monetary Fund | April 2019
- PDF pagination marker: 1

*Source: ch4annex - ANNEX 1. GRAVITY MODEL, DATA, AND ESTIMATION (April 2019 World Economic Outlook).*

### Annex 1. Gravity Model, Data, and Estimation

### Annex 1. Gravity Model, Data, and Estimation

### Model specification
- Aggregate multiplicative gravity representation (equation (1)) for gross exports X_ijt:
  - Core macroeconomic regressors: gross output Y_it (exporter), gross expenditure E_jt (importer), and gross world output Y_wt = ∑Y_it.
  - Trade cost components: physical distance, common language, common colonial history, border, dummy for free/preferential/regional trade agreements FTA_ijt, bilateral tariffs τ_ijt (goods only).
  - Multilateral resistance terms (MRT): outward MRT_out_it and inward MRT_in_jt included.
  - Home-bias dummy S M_ij s (intra-national trade = 1) interacted with geographic variables to allow different distance elasticities for intra- and international trade.
  - Services vs non-services: non-tariff cost variables are interacted with a service-sector dummy.

- Functional and estimation choices:
  - σ is set to 3 in baseline (robust to setting σ=2).
  - Coefficients on output and expenditure are constrained to 1 in baseline sectoral specification (β1 = β2 = 1); coefficients on MRT terms constrained equal (β12 = β13) in baseline.
  - Alternative specifications: partially unconstrained (MRT unconstrained), fully unconstrained (output/expenditure and MRT unconstrained).
  - Estimator: pseudo Poisson maximum likelihood (PPML) (Silva and Tenreyro, 2006) to include zero trade flows and account for heteroscedasticity.
  - Robustness: aggregate vs sectoral regressions, inclusion of non-tariff measures (NTMs), country-pair fixed effects, cross-section estimates at five-year horizons.

### Multilateral resistance: two-step construction and predicted trade costs
- First-step MRT proxy: bilateral GDP-weighted distance (Wei (1996) style):
  - MRT_it = (∑ (Y_jt / Y_wt) ⋅ Distance_ij^(1−σ) _j )^(1/(1−σ)), with σ = 3.
- Predicted bilateral trade costs T̂_ijt built from estimated coefficients on tariffs and other cost components:
  - T̂_ijt = exp{ −[ estimated cost component linear index ]/(1−σ) }.
- Final MRTs constructed using predicted trade costs:
  - MRT_out_it = (∑ (Y_jt / Y_wt) ⋅ T̂_ijt^(1−σ) _j )^(1/(1−σ))
  - MRT_in_jt = (∑ (Y_it / Y_wt) ⋅ T̂_jit^(1−σ) _i )^(1/(1−σ))
- Note: because of Y_wt weighting, countries with low world output shares have negligible effects on MRTs and bilateral exports.

### Data
- Trade datasets:
  - OECD TiVA 2016: bilateral exports and gross production at ISIC 3, 34 sectors, 63 countries, 1995-2011.
  - OECD TiVA 2018: ISIC 4, 34 sectors, 63 countries, 2005-2015.
  - Databases combined by splicing 2016 forward from 2006 using change in global GDP shares from 2018 TiVA.
  - Final sector count: 33 sectors (two sectors combined in each database).
  - Constructed intra-national trade = gross production − exports; negative constructed values at sector level set to zero.
  - Country-sector gross expenditure built from OECD input-output tables.
  - Alternative importer expenditure measure in robustness: GDP plus imports from IMF WEO.
  - World gross production = sum of all country-sector gross output observations from TiVA.

- Trade cost and auxiliary data:
  - Tariffs: WITS, aggregated to sector level with trade-weighted averaging; tariffs set to zero for all service sectors.
  - Other trade-cost variables (distance, colonial history, contiguity, common language, FTAs): CEPII (Head, Mayer, and Riess (2010); Head and Mayer (2014)).
  - Non-tariff measures (NTMs): UNCTAD TRAINS database; many missing sector-level NTMs treated as zero.

### Results — sectoral and country-level estimation (key coefficients and fit)
- Estimation frame: sectoral gravity regression on 5-year average panels, constrained baseline and alternative specifications.

- Selected baseline sector-level coefficient estimates (Table 1, column (1) baseline, constrained, distance-MRT):
  - LN(Distance_ij)*(1−SM_ij)*(Non-Service): -1.081*** (standard error 0.0607)
  - LN(Distance_ij)*SM_ij*(Non-Service): -1.828*** (0.0888)
  - LN(Distance_ij)*(1−SM_ij)*(Service): -1.176*** (0.0600)
  - LN(Distance_ij)*SM_ij*(Service): -1.818*** (0.0928)
  - LN(1 + Tariff_ijt): -1.918*** (0.410)
  - LN(World Gross Output_T): -0.952*** (0.0585)
  - SM_ij (intra-national dummy): 6.665*** (0.625)
  - LN(MRT_distance_it): 0.932*** (0.0426)
  - LN(MRT_distance_jt): 0.932*** (0.0426)
  - Observations: 475,567
  - R-squared: 0.947

- Selected robustness and alternative estimates (Table 1, column (2) predicted-cost MRT):
  - LN(1 + Tariff_ijt): -1.769*** (0.397)
  - LN(World Gross Output_T): -1.005*** (0.0273)
  - SM_ij: 7.471*** (0.532)
  - LN(MRT_cost_it): 1.020*** (0.0184)
  - LN(MRT_cost_jt): 1.020*** (0.0184)
  - Observations: 474,933
  - R-squared: 0.962

- Cross-section sectoral estimates by period (Table 2):
  - LN(1 + Tariff_ijt) coefficients vary by period; e.g., 1995: -0.0246 (0.406), 2000: -2.900*** (0.674), 2005: -3.789*** (0.544), 2010: -1.951*** (0.598), 2015: -1.440*** (0.479).
  - MRT_distance_it and MRT_distance_jt consistently ~1.008–1.033 across periods.
  - Observations by period: 1995: 87,436; 2000: 58,414; 2005: 68,353; 2010: 81,076; 2015: 62,373.
  - R-squared range: 0.959–0.969.

- Country-level (5-year average panel) selected estimates (Table 3):
  - LN(1+Tariff_ijt) (country-level, constrained/various): e.g., columns report -5.397*** (1.189), -5.359*** (1.138), -4.776*** (1.136), -4.207*** (0.538), -4.562*** (1.050) across specifications.
  - LN(MRT_distance_it), LN(MRT_distance_jt): 0.919*** (0.0694)
  - SM_ij: 6.722*** to 7.554*** depending on specification.
  - Observations (country-level): ~15,560 (various slight differences across columns).
  - R-squared up to 1.000 in specifications with country-pair fixed effects.

- Trade-balance fit (Table 4, sector level, 5-year average panel):
  - Regression of actual bilateral trade balances on predicted bilateral trade balances.
  - Predicted Bilateral Trade Balance coefficient (constrained, MRT-distance): 0.938*** (0.244) — Observations 15,876 — R-squared 0.235.
  - Predicted Bilateral Trade Balance coefficient (constrained, MRT-cost): 1.053*** (0.214) — R-squared 0.288.
  - Period-specific cross-sections show coefficient instability in some periods (e.g., 2010 coefficient -0.0945 (0.235)).
  - R-squared for sub-sample of largest bilateral balances generally higher (e.g., up to 0.535 in some periods).

- Trade-balance fit (Table 5, country level, 5-year average panel):
  - Predicted trade balance (constrained, MRT-distance) regressed on actual trade balance (demand as gross expenditure): coefficient 0.799*** (0.207), Observations 15,282, R-squared 0.260.
  - Predicted trade balance (constrained, MRT-cost): 0.972*** (0.186), R-squared 0.314.
  - Predicted trade balance with country-pair fixed effects (constrained): coefficient 1.001*** (0.0286), R-squared 0.931.
  - Unconstrained specifications produce larger coefficients (e.g., 2.287*** (0.304)) but lower overall fit for some specifications.
  - Conclusion: gravity model explains levels of bilateral trade balances less well than it explains unidirectional exports; fit improves substantially with country-pair fixed effects and for largest bilateral balances.

- Interpretation of tariffs and NTMs:
  - Tariffs estimated to have a negative and significant impact on gross bilateral exports; elasticity broadly consistent with σ = 3 assumption in MRT construction.
  - Inclusion of NTMs decreases the estimated tariff impact only very minorly, suggesting NTMs have a separate and important impact on trade.

### Predicting bilateral trade balances and decomposition methodology
- Construction:
  - Bilateral imports constructed by inverting exporter estimates (column (2) of Table 1) to importer perspective, enabling predicted bilateral trade balances at aggregate or sectoral level.
  - Actual bilateral trade balances regressed on predicted values: TB_ijt = α + β TB̂_ijt + ε_ijt.
  - Gravity model explains gross exports well; explains levels of bilateral trade balances less well but explains changes (differences) in bilateral trade balances effectively.

- Approximation for change in sectoral trade balance (multiplicative model):
  - ΔTB_ijst ≈ Δln(X_ijst) ⋅ X_ijst−1 − Δln(X_jist) ⋅ X_jist−1.
  - Using estimated coefficients from Table 1, predicted contributions formed from predicted Δln of regressors normalized by initial (t−1) bilateral exports/imports (initial values are actual, not predicted).
  - The sectoral ΔTB expression (expanded) includes terms for:
    - Domestic net-supply: β̂1 Δln(Y_ist) ⋅ X_ijst−1 − β̂2 Δln(E_ist) ⋅ X_jist−1
    - Net-demand: β̂2 Δln(E_jst) ⋅ X_ijst−1 − β̂1 Δln(Y_jst) ⋅ X_jist−1
    - World output term: β̂3 ⋅ (X_ijst−1 − X_jist−1) ⋅ Δln(Y_wt)
    - Multilateral costs, bilateral costs, FTAs, NTMs, and sectoral composition contributions defined analogously.
  - Sectoral shares used to isolate sectoral specialization effects: Y_ist = s_ist^Y ⋅ Y_it and E_jst = s_jst^E ⋅ E_jt.
  - Aggregate contributions obtained by summing sectoral contributions across s.

- Results of decomposition:
  - Figures (A1–A3) provide trade-balance contribution charts for large bilateral balance changes (sectoral/model variations); NTMs contribute negligibly to most bilateral trade balances.
  - Gravity model explains changes in bilateral trade balances well; levels are better explained when country-pair fixed effects are included.

### Key methodological notes and robustness
- PPML estimation is central given prevalence of zero trade flows at sector level and heteroscedasticity.
- MRT proxies: initial GDP-weighted-distance proxies (σ = 3) used as first-step, then predicted-cost MRTs constructed from estimated trade-cost coefficients; results robust across MRT constructions.
- Constrained baseline (β1 = β2 = 1; β12 = β13) retained for theoretical appeal despite some unconstrained estimates showing β̂1 and β̂2 < 1 (but ~0.8 when using only international trade observations).
- Country-pair fixed effects capture bilateral time-invariant trade costs and substantially improve trade-balance level fit.
- Robustness exercises include using GDP plus imports as importer-expenditure measure (to capture global value chain effects), NTMs inclusion (many missing assumed zero), cross-section estimates at five-year horizons, and comparisons between sectoral and aggregate specifications.

*International Monetary Fund | April 2019*

### Annex 2. Derivation of Relation Between Bilateral and Aggregate Trade Balances

### Annex 2. Derivation of Relation Between Bilateral and Aggregate Trade Balances

### Gravity equation framework and definitions
- Nominal exports X_{ij} from country i to j are expressed as:
  X_{ij} = Y_i E_j / Y_w (τ_{ij} Π_i / P_j)^{1−σ}
- Definitions and parameters:
  - Y_i and Y_w: production in country i and for the world.
  - E_j: total spending of country j.
  - σ: aggregate trade elasticity.
  - Multilateral resistance terms (MRTs):
    - Outward MRT Π_i: average of all the tariffs faced in the global market by the exporting country.
    - Inward MRT P_j: overall tariff that the importing country imposes on the rest of the world.
  - MRT expressions:
    - Π_i = [∑_j θ_j (τ_{ij} / P_j)^{1−σ}]^{1/(1−σ)}
    - P_j = [∑_i θ_i (τ_{ij} / Π_i)^{1−σ}]^{1/(1−σ)}
  - θ_i = y_i / y_w: share of country i's nominal output in world output.
- Empirical note:
  - MRTs are typically accounted for using country fixed effects; the chapter instead avoids fixed effects and controls for MRTs using literature-proposed proxies.
  - In the short term, output shares are treated as fairly stable; short-term changes in trade intensities are driven almost entirely by changes in bilateral trade costs.

### Derivation of relation between bilateral and aggregate trade balances
- With Y proxied by GDP and spending E by domestic absorption E_j = Y_j − TB_j, and assuming symmetric trade costs τ_{ij} = τ_{ji} ⇒ Π_i = P_i, the gravity equation can be rewritten as:
  X_{ij} / (Y_i Y_j / Y_W) = m_{ij} (1 − TB_j / Y_j)
  - m_{ij} is a trade intensity (trade bias), a function of bilateral trade costs and MRTs.
- Under symmetric trade costs, trade intensities are symmetric: m_{ij} = m_{ji}.
- Scaled bilateral trade balance between two countries:
  TB_{ij} / (Y_i Y_j / Y_W) = (X_{ij} − X_{ji}) / (Y_i Y_j / Y_W) = m_{ij} (TB_i / Y_i − TB_j / Y_j)
- Empirical implementation:
  - Estimates of bilateral trade intensity m_{ij} are obtained by substituting predicted bilateral exports X̂_{ij} from the gravity equation into the identity above.
  - Any trade balance-to-GDP ratio on the right-hand side can be decomposed into its EBA determinants (as implemented in the chapter).
  - The relation is used in Box 2 to calculate an average trade intensity between the United States and China by deriving a time series for m_{ij} as an unobservable residual from 1997 to 2014 and then averaging.

### Key analytical implications and empirical remarks
- The identity links bilateral trade balances to aggregate trade balance-to-GDP ratios scaled by bilateral trade intensity m_{ij}.
- Short-term analysis treats output shares as exogenous/stable, so changes in bilateral balances reflect changes in bilateral trade costs and MRTs.
- Practical estimation:
  - MRTs approximations rely on output shares being close to spending shares; approximation error is small for empirically relevant aggregate imbalances.
  - The chapter’s regression strategy avoids country fixed effects and instead uses proxies for MRTs to identify trade intensities.

*Source: Annex 2. Derivation of Relation Between Bilateral and Aggregate Trade Balances (ch4annex).*

---


_Source: https://www.imf.org/-/media/files/publications/weo/2019/april/english/ch4annex.pdf_
