You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In the openENTRANCE project, we introduced a > character to define "directional" variable, for example trade flows from Country A to Country B. The region code then has the structure: Austria>Germany, see here for more info.
It would be useful that the nomenclature validation also checks that for any "directional" code in the region list, there can only be two components (Austria>Germany>France) is invalid and both components must be valid regions.
See here for the current prototype in the openENTRANCE workflow.
The text was updated successfully, but these errors were encountered:
danielhuppmann
changed the title
Validate "directional" data
Validate "directional" region code
Sep 14, 2022
PR openENTRANCE/openentrance#296 ran into a similar issue, where the region-mapping fails unless a directional region code Austria>Germany is not stated explicitly in the mapping.
Possible solutions for the region-validation:
Add a keyword-argument allow_directional=False (or similar) when initializing a DataStructureDefinition
Add a config-file in the "definitions/region" folder
Add an attribute to the RegionCodeList which can set after initializing a DataStructureDefinition
e.g., dsd.region.allow_directional = True
in each of these cases, any possible combination x>y will be added to the RegionCodeList. Question is how to determine a suitable "hierarchy" name.
Possible solution for the region-processing:
Add an attribute allow_directional to the region-mapping file.
Note that this solution must also take care of renaming, so that if "AT" is renamed to "Austria", then "AT>..." must also be renamed to "Austria>".
In the openENTRANCE project, we introduced a
>
character to define "directional" variable, for example trade flows from Country A to Country B. The region code then has the structure:Austria>Germany
, see here for more info.It would be useful that the nomenclature validation also checks that for any "directional" code in the region list, there can only be two components (
Austria>Germany>France
) is invalid and both components must be valid regions.See here for the current prototype in the openENTRANCE workflow.
The text was updated successfully, but these errors were encountered: