Description Usage Arguments Details Value Examples
Spread quantity data along the period and write to a csv file Write a data frame containing trade flows to a csv file
1 2 3 4 5 | formatflows(dtf)
write2csv_spread(dtf, csvfile)
write2csv_long(dtf, csvfile)
|
dtf |
a data frame containing validated trade flows |
csvfile |
character path to a csv file |
formatflows
edits information so that the exported data
is more pleasant to use.
For example missing partner is replaced by the partnercode
Long descriptions are truncated.
The input data frame invisibly
1 2 3 4 5 6 7 8 9 10 | ## Not run: # Clean product and country codes
con <- RMariaDB::dbConnect(RMariaDB::MariaDB(), dbname = "test")
csvfile <- tempfile(fileext = ".csv")
loadflows(con, productanalysed = "44071190", periodstart = 201700,
tableread = "vld_comext_monthly") %>%
write2csv_spread(csvfile)
readLines(csvfile,5) # Check the first lines of the csv file
RMariaDB::dbDisconnect(con)
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.