Skip to contents

Data Access

Fetch trade flows from the UN Comtrade API

ct_trade()
Get Bilateral Trade Data
ct_services()
Get Services Trade Data
ct_reporters()
List Reporter Countries
ct_commodities()
Search Commodity Codes
ct_set_key()
Set the Comtrade API Key
ct_available()
Check Data Availability

Analysis

Trade indicators and market structure

ct_rca()
Revealed Comparative Advantage (Balassa Index)
ct_hhi()
Trade Concentration Index (HHI)
ct_balance()
Trade Balance by Partner
ct_growth()
Trade Growth Over Time
ct_share()
World Trade Share
ct_top_partners()
Top Trading Partners
ct_top_products()
Top Export or Import Products
ct_compare()
Compare Countries
ct_concordance()
Convert Between Trade Classifications

Utilities

Cache management

ct_cache_clear()
Clear the Comtrade Cache

Package

comtrade comtrade-package
comtrade: Access and Analyse UN Comtrade International Trade Data