Closed brockfanning closed 3 years ago
Here is an example of this in action: http://brock.tips/fcdo-kg-data/
Notice there are two SDMX outputs - the second one is the global.
@brockfanning looks good
Should the global series be both in the global output and national output?
I've just been having quick look at files to check if it's constraining properly but I'm not sure about one of the series:
It's in both outputs i.e. global and national
EDIT: ignore my question, I'm pretty sure that's right actually!
Yep, it's OK for "KG" to be in the "global" output, since that code is in the global DSD. The ones that are dropped from the global output the subnational codes, like "KG01", "KG02", etc.
This adds functionality to make it easier to produce globally-compatible SDMX output. Here are the features in this PR:
output_subfolder
which can be used to change the defaultsdmx
subfolder. This allows you to have multiple SDMX outputs (such as one national and one global).global_content_constraints
. If set to true, this will drop all rows of data that don't meet the global content constraints per series. (For example, this drops data for series SI_COV_MATNL if SEX is not set to F.) If thelogging
parameter includes 'warn', then details about the errors will be logged during the build.The YAML config file for Open SDG has a new option:
sdmx_output_global
. This works exactly the same as thesdmx_output
option, except that the follow parameters are automatically set:If no other customizations are needed beyond these, then the
sdmx_output_global
can simply be set totrue
. Example:Otherwise it can have all the same parameters as the existing
sdmx_output
option. Example:Both the existing
sdmx_output
and the newsdmx_output_global
can be used at the same time.