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

World trade calculation #81

Open
paulgirard opened this issue Jun 17, 2022 · 0 comments
Open

World trade calculation #81

paulgirard opened this issue Jun 17, 2022 · 0 comments

Comments

@paulgirard
Copy link
Member

paulgirard commented Jun 17, 2022

discard GPH depencies and city_part_of

When calculating the wrold trade estimations we sum total trade from reporting by using their total (as reported) or their bilateral trade (sum partners).
When doing this we should remove from the calculation the reporting which are geopolitcal dependencies of sovereign (as stated by GPH) for which we have trade data.
Same diée with part of

Pseudo algo to do thata :

# load over status over time GPH
for each status 
    add a "reporting_GPH_status" in ricardo flows (flag all flows of status years)
    add a "reporting_sovereign" in ricardo flows (flag all flows of status years)

group flow by year, reporting sovereign filter (reporting_ GPH_status == "part_of")
    how many trade flows which are not total trade estimations for this reporting
    if this number > 0 add a "ignore_in_world_sumpartners_reported_calculation"

Ignore flows in world trade calculation (made in API)

discard overlaping group or entities

It can happen to have two series of trade for A and A & B for the same year from different sources.

Piority being assesed by:

  • source type : primary, primary_yearbook, secondary, estimation
  • GPH status: sovereign...
  • RICtype : GPH_entity above all others
@paulgirard paulgirard changed the title World trade calculation counts entities and theirs parts if available World trade calculation Jun 17, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant