knitr::opts_chunk$set( collapse = TRUE, comment = "#>" )
Loads disaggregated data on bilateral trade flows for more than 5000 products and 200 countries. The data is from the CEPII and is built from data directly reported by each country to the United Nations Statistical Division (Comtrade).
As all of the data is packed into one single .zip file in the website, data on all years must be downloaded, even if not all of it is used. Therefore, downloading the data can take a long time.
Options:
dataset: there is one choice:
"HS92"
which follows the Harmonized System methodraw_data: there are two options:
TRUE
: if you want the data as it is originally.FALSE
: if you want the treated version of the data. time_period: picks the years for which the data will be downloaded
language: you can choose between Portuguese ("pt")
and English ("eng")
Examples:
# download treated data for 2016 (takes a long time to download) clean_baci <- load_baci( raw_data = FALSE, time_period = 2016 )
Any scripts or data that you put into this service are public.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.