Skip to content

Commit

Permalink
Merge branch 'master' into average_line
Browse files Browse the repository at this point in the history
  • Loading branch information
Amy-Reidy committed Jul 3, 2024
2 parents 348db1a + 128427b commit 955e510
Show file tree
Hide file tree
Showing 5 changed files with 41 additions and 14 deletions.
11 changes: 4 additions & 7 deletions dash_service/pages/transmonee.py
Original file line number Diff line number Diff line change
Expand Up @@ -1894,23 +1894,20 @@ def get_base_layout(**kwargs):
"color": '#374EA2',
"margin-left": "20px",
"margin-right": "5px",
"display":"none",
},
),
html.A(
"Explore CRC Recommendations Dashboard",
href="https://public.tableau.com/app/profile/ecaro.data/viz/RecommendationsoftheCommitteeontheRightsoftheChild/Overview",
href="https://www.transmonee.org/recommendations-committee-rights-child",
target="_blank",
className="tm-link",
style={
"color": '#374EA2',
"text-decoration": "underline",
"display":"none",
},
),
],
className="crc-link",
style={"display": "none"},
),
],
),
Expand Down Expand Up @@ -2916,7 +2913,7 @@ def aio_area_figure(
df_indicator_sources = df_sources[df_sources["Code"] == base_indicator]
unique_indicator_sources = df_indicator_sources["Source_Full"].unique()

if data["CODE"].isin(["DM_CHLD_POP", "DM_CHLD_POP_PT", "DM_FRATE_COMP"]).any():
if data["CODE"].isin(["DM_CHLD_POP", "DM_CHLD_POP_PT", "DM_FRATE_COMP","DM_ADOL_POP", "DM_UFIVE_POP"]).any():
source = "Multiple Sources"
elif len(unique_indicator_sources) > 0:
source = "; ".join(list(unique_indicator_sources))
Expand All @@ -2926,8 +2923,8 @@ def aio_area_figure(
source_link = (
df_indicator_sources["Source_Link"].unique()[0]
if len(unique_indicator_sources) > 0
and not data["CODE"].isin(["DM_CHLD_POP", "DM_CHLD_POP_PT", "DM_FRATE_COMP"]).any()
else ""
and not data["CODE"].isin(["DM_CHLD_POP", "DM_CHLD_POP_PT", , "DM_FRATE_COMP", "DM_ADOL_POP", "DM_UFIVE_POP"]).any()
else "https://ec.europa.eu/eurostat/cache/metadata/en/demo_pop_esms.htm"
)

options["labels"] = DEFAULT_LABELS.copy()
Expand Down
Binary file modified dash_service/static/Full CRC database.xlsx
Binary file not shown.
13 changes: 13 additions & 0 deletions dash_service/static/indicator_config.json
Original file line number Diff line number Diff line change
Expand Up @@ -261,6 +261,19 @@
]
}
},
"DM_UFIVE_POP": {
"SEX": {
"SEX": [
"F",
"M"
]
},
"TOTAL": {
"SEX": [
"_T"
]
}
},
"DM_ADOL_YOUTH_POP": {
"AGE": {
"AGE": [
Expand Down
3 changes: 2 additions & 1 deletion dash_service/static/indicator_definitions.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,8 @@
"DM_CHLD_NSO": "Child population (0-17 years) at the beginning of the year",
"FT_WHS_PBR": "The number of babies born alive before 37 weeks of pregnancy are completed, per 100 live births per year.",
"MT_SP_DYN_CDRT_IN": "Crude death rate (per 1,000 average population)",
"DM_ADOL_POP": "Total adolescent population aged 10-19 years",
"DM_ADOL_POP": "Population of adolescents aged 10-19 years, compiled from multiple sources according to the country's preference. Data comes from Eurostat, UN DESA or in some cases it has been directly submitted by the NSO (for Belarus, Georgia and Tajikistan).",
"DM_UFIVE_POP": "Population of children under five years old, compiled from multiple sources according to the country's preference. Data comes from Eurostat, UN DESA or in some cases it has been directly submitted by the NSO (for Belarus, Georgia and Tajikistan).",
"DM_TOT_POP_PROSP": "Total population prospects (in thousands)",
"DM_ADOL_YOUTH_POP": "Total adolescent, young and youth population aged 10-24 years",
"DM_ADULT_YOUTH_POP": "Total adult youth population aged 20-29 years",
Expand Down
28 changes: 22 additions & 6 deletions dash_service/static/page_config.py
Original file line number Diff line number Diff line change
Expand Up @@ -114,6 +114,8 @@

min_max_card_suffix = "min - max values"
number_children = "Number of children"
number_adolescents = "Number of adolescents"
number_underfive = "Number of children under 5 years"
percentage_children = "Percentage of children"
number_people = "Number of people"
percentage_people = "Percentage of people"
Expand Down Expand Up @@ -1322,7 +1324,7 @@
'min_max': True,
'yaxis': 'Percentage of population',
'button_name': 'Population living below the national poverty line (SDG 1.2.1)'},
{'name': 'People at risk of poverty or social exclusion',
{'name': 'Percentage of people at risk of poverty or social exclusion',
'indicator': 'PV_AROPE',
'suffix': min_max_card_suffix,
'min_max': True,
Expand All @@ -1334,7 +1336,7 @@
'min_max': True,
'yaxis': 'Severe material and social deprivation rate',
'button_name': 'Severe material and social deprivation rate'},
{'name': 'At-risk-of-poverty rate by threshold: 60% of national median equivalized disposable income after social transfers',
{'name': 'At-risk-of-poverty rate',
'indicator': 'PV_AROPRT',
'suffix': min_max_card_suffix,
'min_max': True,
Expand Down Expand Up @@ -1561,7 +1563,13 @@
'default_graph': 'bar',
'default': 'HT_REG_CHLD_DISAB_PROP'}},
'ECD': {'NAME': 'Early childhood development',
'CARDS': [{'name': '4.2.1. Percentage of children (36-59 months) developmentally on track in at least 3 of the 4 following domains: literacy-numeracy, physical, social-emotional and learning',
'CARDS': [{'name': 'Under-five population',
'indicator': 'DM_UFIVE_POP',
'suffix': 'children',
'min_max': False,
'yaxis': number_underfive,
'button_name': 'Under-five population'},
{'name': '4.2.1. Percentage of children (36-59 months) developmentally on track in at least 3 of the 4 following domains: literacy-numeracy, physical, social-emotional and learning',
'indicator': 'ECD_CHLD_36-59M_LMPSL',
'suffix': min_max_card_suffix,
'min_max': True,
Expand Down Expand Up @@ -1604,7 +1612,8 @@
'yaxis': percentage_children,
'button_name': 'Pupils from age 3 to the starting age of compulsory education at primary level'}],
'AIO_AREA': {
'indicators': ['ECD_CHLD_36-59M_LMPSL',
'indicators': ['DM_UFIVE_POP',
'ECD_CHLD_36-59M_LMPSL',
'CME_MRM0-ECD',
'NT_BF_EXBF-ECD',
'ECD_CHLD_24-59M_ADLT_SRC',
Expand All @@ -1614,7 +1623,13 @@
'default_graph': 'bar',
'default': 'ECD_CHLD_36-59M_LMPSL'}},
'ODA': {'NAME': 'Adolescents',
'CARDS': [{'name': 'Adolescent birth rate - SDG 3.7.2 (adolescents sub-domain)',
'CARDS': [{'name': 'Adolescent population (10-19 years)',
'indicator': 'DM_ADOL_POP',
'suffix': 'adolescents',
'min_max': False,
'yaxis': number_adolescents,
'button_name': 'Adolescent population'},
{'name': 'Adolescent birth rate - SDG 3.7.2 (adolescents sub-domain)',
'indicator': 'FT_SP_DYN_ADKL-ADO',
'suffix': min_max_card_suffix,
'min_max': True,
Expand Down Expand Up @@ -1663,7 +1678,8 @@
'yaxis': 'Percentage of population',
'button_name': 'Privacy and protection of personal data'}],
'AIO_AREA': {
'indicators': ['FT_SP_DYN_ADKL-ADO',
'indicators': ['DM_ADOL_POP',
'FT_SP_DYN_ADKL-ADO',
'MT_SDG_SUICIDE-ADO',
'EDU_SDG_YOUTH_NEET-ADO',
'EDU_SDG_STU_L2_GLAST_MAT-ADO',
Expand Down

0 comments on commit 955e510

Please sign in to comment.