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

3203 Forest area as proportion of total land area SDG - should be estimated bases on the latest available NDP after 2020 #3427

Conversation

sorja
Copy link
Contributor

@sorja sorja commented Jan 22, 2024

The calculation formula became a bit more complicated when we must know the latest year, added a new file

  • Introduced expressionEvaluator/functuions/calculations/

Todo:

  • Calculation: Verify and understand the logic for all different cases

Developer note: After a bit of slight annoyance that record format was not supported in calculations (is it..? probably not?) opened an issue to migrate from arena-core and add support for record format (plugin for jsep)
#3426

Developer note2:

This is the old calculation formula as reference (year 2023)
extentOfForest.forestArea['2023'] ? extentOfForest.forestArea['2023'] / extentOfForest.totalLandArea['2023'] * 100 : ((extentOfForest.forestArea['2020'] / extentOfForest.totalLandArea['2020'] * 100 > 0 && extentOfForest.forestArea['2025'] / extentOfForest.totalLandArea['2025'] * 100) > 0 ? (extentOfForest.forestArea['2020'] / extentOfForest.totalLandArea['2020'] * 100 + ((extentOfForest.forestArea['2025'] / extentOfForest.totalLandArea['2025'] * 100 - extentOfForest.forestArea['2020'] / extentOfForest.totalLandArea['2020'] * 100) / 5 * 3)) : null)

sorja added 3 commits March 5, 2024 13:55
…al-land-area-sdg-should-be-estimated-bases-on-the-latest-available-ndp-after-2020
@sorja sorja requested a review from minotogna March 7, 2024 13:12
…al-land-area-sdg-should-be-estimated-bases-on-the-latest-available-ndp-after-2020
@sorja sorja marked this pull request as ready for review March 7, 2024 13:12
@sorja sorja marked this pull request as draft March 8, 2024 07:05
@sorja sorja requested a review from minotogna March 8, 2024 11:50
…al-land-area-sdg-should-be-estimated-bases-on-the-latest-available-ndp-after-2020
@sorja sorja marked this pull request as ready for review March 8, 2024 11:51
@mergify mergify bot merged commit c6658b4 into development Mar 8, 2024
5 checks passed
@mergify mergify bot deleted the 3203-forest-area-as-proportion-of-total-land-area-sdg-should-be-estimated-bases-on-the-latest-available-ndp-after-2020 branch March 8, 2024 12:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants