Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Nonsensical regional detail in historical.mif #194

Open
0UmfHxcvx5J7JoaOhFSs5mncnisTJJ6q opened this issue Jan 20, 2022 · 4 comments
Open
Assignees
Labels
bug Something isn't working

Comments

@0UmfHxcvx5J7JoaOhFSs5mncnisTJJ6q
Copy link
Member

This

calcOutput("Historical", round = 5, file = "historical.mif", aggregate = "region+global+missingH12")

writes Production|Industry|Cement and Production|Industry|Steel (and possibly others) in regional detail to historical.mif, when the source (readIEA(subtype = 'industry')) only contains global data. The disaggregation using GDP figures and re-aggregation lead to nonsensical data that is distracting and misleading during validation.
image
Is there a way to have only global data for these variables in the file?

@0UmfHxcvx5J7JoaOhFSs5mncnisTJJ6q
Copy link
Member Author

Tagging @fbenke-pik since he seems to be involved with redesigning historical.mif.

@fbenke-pik
Copy link
Contributor

fbenke-pik commented Jan 21, 2022

Thanks for bringing this up, @0UmfHxcvx5J7JoaOhFSs5mncnisTJJ6q

This issue comes up in other sources as well and I had to exclude valid data from historical.mif due to this problem before, e.g. IEA WEO 2021 free data set only has global data for most of the variables. In consequence, we cannot include data on GLO level, because the disaggregation on country-level produces inaccurate data we do not want in historical.mif. So would be great to be allowed to include data only on global level for some variables in calcOutput instead of being forced to always provide all 249 countries. If you then call calcOutput without the GLO aggregation, the GLO-only data simply wont be included.

@tscheypidi
Copy link
Member

I think a mix of global and regional values in a single calcOutput does not work, but you can have a calc-function for global data and one for regional data and for the data you want to use only on global level you can then run calcOutput(..., aggregate="glo")

@0UmfHxcvx5J7JoaOhFSs5mncnisTJJ6q
Copy link
Member Author

0UmfHxcvx5J7JoaOhFSs5mncnisTJJ6q commented Jan 21, 2022

I think a mix of global and regional values in a single calcOutput does not work, but you can have a calc-function for global data and one for regional data and for the data you want to use only on global level you can then run calcOutput(..., aggregate="glo")

So calcHistorical() would call calcOutput('Historical_global', …, aggregate = 'glo') and calcOutput('Historical_regional', …)? And by calcOutput('Historical', …) we would get one magclass object with lots of NAs for the global data in the regions, which would also get written to historical.mif?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

6 participants