Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- library(imfr)
- library(tidyverse)
- library(stringr)
- library(knitr)
- # See what databases are available
- databases <- imf_databases()
- # Explore the parameters of a specific database (IFS)
- params_ifs <- imf_parameters(database_id = "IFS")
- # Get a list of all possible code lists for the IFS database
- param_codelist_ifs <- imf_codelist(database_id = "IFS")
- # Get all possible indicator codes for the IFS database
- IFS_INDICATOR_codes <- imf_codes(codelist = "CL_INDICATOR_IFS")
- # Download the dataset
- IFS_data <- imf_dataset(database_id = "IFS",
- freq = "Q", ref_area = "VN",
- indicator = c("FPOLM_PA", "FIDR_PA", "FILR_PA","PCPI_IX","AIPMA_IX","AIP_IX","LLF_PE_NUM","LE_PE_NUM","LU_PE_NUM","LUR_PT"))
- # save data
- write.csv(IFS_data, "path/data.csv")
Advertisement
Add Comment
Please, Sign In to add comment