Product-to-Product Distances in the CN Product Space
This page provides the data underlying the CN4 product-to-product distance visualization in Who Can Produce What? Firm Capabilities and Product Entry, by Luca Macedoni, John Morrow, and Vladimir Tyazhelnikov.
The distances are constructed using confidential firm-product data from Statistics Denmark’s Production Statistics (VARS) and International Trade Statistics (UHDI). We use the DGKP approach, which derives firm-product marginal costs from markups estimated following De Loecker et al. (2016). The distances are based on the resulting firm-product absolute advantages and capture both direct and indirect co-production links between products. The paper provides a complete description of their construction.
The data provided here contain the product-to-product distances estimated for 2018 after aggregating products to the four-digit CN level while retaining their units of measurement. At this level, all products belong to a single cluster: every pair is connected through either direct co-production or a chain of indirect co-production.
To preserve confidentiality, we do not report the underlying continuous distances. Instead, we divide them into ten bins, where 1 identifies the closest product pairs and 10 the most distant. The downloadable Stata file contains one observation for each product pair. We also provide the visualization based on these data that appears in the paper.
Variables in the Stata file
Download product-to-product distances (.dta)
Product-pair distances
View product-space visualization
Visualization of the product-to-product distances reported in the paper
Citation
When using these data, please cite:
Luca Macedoni, John Morrow, and Vladimir Tyazhelnikov, “Who Can Produce What? Firm Capabilities and Product Entry,” 2026.
The distances are constructed using confidential firm-product data from Statistics Denmark’s Production Statistics (VARS) and International Trade Statistics (UHDI). We use the DGKP approach, which derives firm-product marginal costs from markups estimated following De Loecker et al. (2016). The distances are based on the resulting firm-product absolute advantages and capture both direct and indirect co-production links between products. The paper provides a complete description of their construction.
The data provided here contain the product-to-product distances estimated for 2018 after aggregating products to the four-digit CN level while retaining their units of measurement. At this level, all products belong to a single cluster: every pair is connected through either direct co-production or a chain of indirect co-production.
To preserve confidentiality, we do not report the underlying continuous distances. Instead, we divide them into ten bins, where 1 identifies the closest product pairs and 10 the most distant. The downloadable Stata file contains one observation for each product pair. We also provide the visualization based on these data that appears in the paper.
Variables in the Stata file
- prod_id1: Identifier for Product 1, defined by its four-digit product code and unit of measurement.
- prod_id2: Identifier for Product 2, defined by its four-digit product code and unit of measurement.
- hnic41: Four-digit product code for Product 1.
- unit1: Unit of measurement for Product 1.
- hnic42: Four-digit product code for Product 2.
- unit2: Unit of measurement for Product 2.
- distance_bin: Binned product-to-product distance. A value of 1 identifies the closest product pairs, while a value of 10 identifies the most distant.
Download product-to-product distances (.dta)
Product-pair distances
View product-space visualization
Visualization of the product-to-product distances reported in the paper
Citation
When using these data, please cite:
Luca Macedoni, John Morrow, and Vladimir Tyazhelnikov, “Who Can Produce What? Firm Capabilities and Product Entry,” 2026.