View source: R/read-spectrum-pop1.R
read_pop1 | R Documentation |
Spectrum has a debug mode option to output a file recording the entire state space when a model simulation is computed. This function parse the *_pop1.xlsx file into long-format data.frame.
read_pop1(pop1file, country, years = 2000:2021)
pop1file |
path to *_pop1.xlsx export file |
country |
string giving the identifying country / region name to be added as a column in the output file |
years |
integer vector of years to extract |
TODO: tidy up the dependencies in this function: reshape, pryr, readxl.
TODO: Insert instructions for how to enter Spectrum debug mode.
'years' must be in the file as sheets, but this is not currently checked. It will fail hard. Inserting a check for this would make it fail softer.
A data.frame consisting of pop1 file in long format
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.