message("you can now develop directly in the inst/tempalte dir, see instruction to compile the pdf in the file there")
library(dplyr)
library(tradeflows)
library(knitr)
library(ggplot2)
options(digits = 4) #  Number of digits in knitr tables
opts_chunk$set(echo=FALSE, message=FALSE)

Product codes at 2, 4 and 6 digit level

sixdigits <- readdbtbl("raw_flow_yearly") %>%
    select(productcode) %>%
    collect() %>% unique()
sixdigits <- sixdigits$productcode
cat("4 digits")
unique(round(sixdigits / 100))
cat("2 digits")
unique(round(sixdigits / 10000))


paul4forest/tradeflows documentation built on Oct. 8, 2019, 10:35 a.m.