Description Usage Arguments Value
View source: R/metis.readgcam.R
This function connects to a gcamdatabase and uses a query file to out results into a table ready for plotting.
1 2 3 4 5 | metis.readgcam(gcamdatabasePath, gcamdatabaseName,
queryxml = "metisQueries.xml", scenOrigNames, scenNewNames = NULL,
reReadData = T, dataProj = "dataProj.proj",
dirOutputs = paste(getwd(), "/outputs", sep = ""),
regionsSelect = NULL, queriesSelect = "All", paramsSelect = "All")
|
gcamdatabasePath |
Path to gcam database folder |
gcamdatabaseName |
Name of gcam database |
queryxml |
Full path to query.xml file |
scenOrigNames |
Original Scenarios names in GCAM database in a string vector. For example c('scenario1','scenario2). |
scenNewNames |
New Names which may be shorter and more useful for figures etc. Default will use Original Names. For example c('scenario1','scenario2) |
reReadData |
If TRUE will read the GCAM data base and create a queryData.proj file in the same folder as the GCAM database. If FALSE will load a '.proj' file if a file with full path is provided otherwise it will search for a dataProj.proj file in the existing folder which may have been created from an old run. |
dataProj |
Optional. A default 'dataProj.proj' is produced if no .Proj file is specified. |
dirOutputs |
Full path to directory for outputs |
regionsSelect |
The regions to analyze in a vector. Example c('Colombia','Argentina') |
queriesSelect |
Default = "All". Vector of queries to read from the queryxml for example c("Total final energy by aggregate end-use sector", "Population by region"). The queries must be availble in the queryxml file. Current list of queries and generated paramaters are:
|
paramsSelect |
Default = "All". If desired select a subset of paramaters to analyze from the full list of parameters: c("finalNrgbySec", "primNrgConsumByFuel", "elecByTech", "watConsumBySec", "watWithdrawBySec", "watWithdrawByCrop", "watBioPhysCons", "irrWatWithBasin","irrWatConsBasin", "gdpPerCapita", "gdp", "gdpGrowthRate", "pop", "agProdbyIrrRfd", "agProdBiomass", "agProdForest", "agProdByCrop", "landIrrRfd", "aggLandAlloc", "LUCemiss", "co2emission", "co2emissionByEndUse", "ghgEmissionByGHG", "ghgEmissByGHGGROUPS") |
A list with the scenarios in the gcam database, queries in the queryxml file and a tibble with gcam data formatted for metis charts.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.