Over-age students, primary, male (% of male enrollment)

Source: worldbank.org, 03.09.2025

Year: 2017

Flag Country Value Value change, % Rank
Albania Albania 6.68 -6% 64
Andorra Andorra 8.4 -7.34% 54
United Arab Emirates United Arab Emirates 4.03 -1.98% 86
Argentina Argentina 6.13 -12.6% 69
Armenia Armenia 2.1 -6.73% 113
Antigua & Barbuda Antigua & Barbuda 5.07 -11.5% 76
Australia Australia 4.15 +0.675% 83
Austria Austria 14.3 +1.5% 31
Azerbaijan Azerbaijan 8.91 +26.6% 49
Burundi Burundi 17.8 -39.3% 17
Belgium Belgium 4.89 +3.02% 78
Benin Benin 9.76 +20.2% 45
Burkina Faso Burkina Faso 15.4 +3.05% 27
Bulgaria Bulgaria 1.93 -14.9% 118
Bahrain Bahrain 2.53 -2.95% 108
Bosnia & Herzegovina Bosnia & Herzegovina 4.07 +9.92% 84
Belarus Belarus 5.25 +6.92% 75
Belize Belize 10.3 +0.598% 44
Bolivia Bolivia 7.14 -15.2% 62
Brazil Brazil 16.1 +3.18% 25
Barbados Barbados 2.4 +2.31% 109
Brunei Brunei 4.32 +3.63% 82
Bhutan Bhutan 13.4 -7.38% 35
Canada Canada 0 146
Switzerland Switzerland 1.63 -8.47% 123
Chile Chile 7.87 -4.43% 57
Côte d’Ivoire Côte d’Ivoire 10.8 -2.55% 42
Cameroon Cameroon 12.7 -14.4% 38
Colombia Colombia 17 -5.11% 23
Comoros Comoros 17.3 -23% 19
Costa Rica Costa Rica 8.8 -26% 50
Cuba Cuba 3.69 -7.79% 92
Cyprus Cyprus 2.03 +10.3% 115
Czechia Czechia 11.8 +1.14% 40
Germany Germany 12.7 -0.0265% 37
Djibouti Djibouti 13.8 -14.8% 33
Denmark Denmark 3.15 -9.62% 100
Dominican Republic Dominican Republic 15.3 -9.46% 29
Algeria Algeria 8.61 +2.86% 52
Ecuador Ecuador 3.63 -20.5% 94
Egypt Egypt 3.06 -8.82% 101
Eritrea Eritrea 26.4 +13.5% 5
Spain Spain 4.83 +2.25% 80
Estonia Estonia 4.03 -1.52% 87
Finland Finland 1.63 +4.37% 124
France France 3.42 -9.32% 96
United Kingdom United Kingdom 1.12 -1.33% 129
Georgia Georgia 2.01 -21.6% 116
Ghana Ghana 17 +1.6% 22
Gambia Gambia 17.3 +0.316% 20
Greece Greece 1.55 +1.09% 126
Grenada Grenada 6.42 -3.92% 66
Guatemala Guatemala 12.4 -7.5% 39
Hong Kong SAR China Hong Kong SAR China 2.72 -2.07% 105
Honduras Honduras 12.9 -7.37% 36
Croatia Croatia 1.04 +18.8% 132
Hungary Hungary 3.38 -0.0485% 98
Indonesia Indonesia 1.07 -0.0747% 131
Ireland Ireland 0.694 +1.27% 138
Iran Iran 4.86 -12.9% 79
Iceland Iceland 0.0487 +29.7% 145
Israel Israel 3.02 +4.04% 103
Italy Italy 5.94 +464% 70
Jamaica Jamaica 6.38 -2.29% 67
Jordan Jordan 1.01 -57% 134
Japan Japan 0 146
Kazakhstan Kazakhstan 0.348 -70.7% 142
Kyrgyzstan Kyrgyzstan 1.09 -28.7% 130
Cambodia Cambodia 15.4 +0.466% 28
Kiribati Kiribati 3.67 -37.1% 93
South Korea South Korea 0.799 -3.18% 137
Kuwait Kuwait 3.3 +5% 99
Laos Laos 13.7 -10.3% 34
Lebanon Lebanon 7.81 -8.18% 58
Liberia Liberia 47.4 -22% 1
St. Lucia St. Lucia 3.73 +0.132% 89
Liechtenstein Liechtenstein 1.96 -2.15% 117
Sri Lanka Sri Lanka 0.927 -2.21% 136
Lesotho Lesotho 23.4 -2.73% 8
Lithuania Lithuania 1.15 -0.875% 128
Luxembourg Luxembourg 3.73 +2.07% 90
Latvia Latvia 3.03 -2.97% 102
Macao SAR China Macao SAR China 5.25 -6.52% 74
Morocco Morocco 15.7 -3.11% 26
Monaco Monaco 5 +163% 77
Moldova Moldova 1.89 +4.46% 119
Maldives Maldives 1.65 -48.5% 122
Mexico Mexico 2.62 -18.7% 106
North Macedonia North Macedonia 1.55 +69.3% 125
Mali Mali 7.5 -32% 60
Malta Malta 1.02 -0.603% 133
Myanmar (Burma) Myanmar (Burma) 10.7 +17% 43
Montenegro Montenegro 2.55 +4.94% 107
Mongolia Mongolia 2.84 -17.7% 104
Mozambique Mozambique 18.3 +1.66% 14
Mauritania Mauritania 19 +4.1% 12
Mauritius Mauritius 4.49 -19.6% 81
Malawi Malawi 20.2 +0.78% 9
Malaysia Malaysia 0.288 -2.29% 143
Namibia Namibia 18.2 -7.35% 15
Niger Niger 7.94 -3.77% 55
Netherlands Netherlands 5.76 -7.41% 73
Norway Norway 0 146
Nepal Nepal 25.3 +2.55% 7
New Zealand New Zealand 0.428 +14.4% 141
Oman Oman 2.34 -17.8% 110
Pakistan Pakistan 26.3 -0.00407% 6
Panama Panama 9.18 -6.73% 48
Peru Peru 6.25 -4.15% 68
Philippines Philippines 11.5 -26% 41
Poland Poland 1.25 -22.3% 127
Portugal Portugal 9.25 -5.9% 47
Palestinian Territories Palestinian Territories 1.7 -5.07% 121
Qatar Qatar 2.31 -2.19% 111
Romania Romania 3.84 +6.25% 88
Russia Russia 3.56 +52,556% 95
Rwanda Rwanda 27 -0.999% 4
Saudi Arabia Saudi Arabia 3.4 -49.2% 97
Sudan Sudan 19 -24.5% 11
Senegal Senegal 9.32 -12.4% 46
Singapore Singapore 0.589 -0.704% 139
Solomon Islands Solomon Islands 36.8 -1.27% 2
Sierra Leone Sierra Leone 8.62 -10.7% 51
El Salvador El Salvador 16.4 -1.1% 24
Serbia Serbia 0.968 +7.01% 135
São Tomé & Príncipe São Tomé & Príncipe 14.2 -17.2% 32
Suriname Suriname 18.9 -2.75% 13
Slovakia Slovakia 17 -1.15% 21
Slovenia Slovenia 2.19 +7.35% 112
Sweden Sweden 18.2 +6.45% 16
Eswatini Eswatini 31 +3.41% 3
Seychelles Seychelles 4.03 +5.74% 85
Togo Togo 17.8 -4.58% 18
Tajikistan Tajikistan 0.0903 -22.1% 144
Timor-Leste Timor-Leste 19.6 -3.42% 10
Tunisia Tunisia 5.93 +11.6% 72
Turkey Turkey 2.07 -41.5% 114
Ukraine Ukraine 7.93 +11.7% 56
Uruguay Uruguay 7.55 -3.73% 59
United States United States 6.47 +18.1% 65
Uzbekistan Uzbekistan 0.465 -49.8% 140
St. Vincent & Grenadines St. Vincent & Grenadines 3.72 +13.4% 91
Venezuela Venezuela 8.5 -2.78% 53
British Virgin Islands British Virgin Islands 5.93 +2.65% 71
Vietnam Vietnam 1.76 -14.2% 120
Samoa Samoa 7.31 -18.1% 61
South Africa South Africa 7.1 -1.71% 63
Zambia Zambia 14.8 +3.35% 30

The indicator 'Over-age students, primary, male (% of male enrollment)' provides insight into the proportion of male students who are older than the typical age for their grade level in primary education. This statistic is pivotal as it highlights discrepancies between age and educational progress, underscoring potential barriers to achieving education for all. Over-age students are often a reflection of systemic issues within educational systems, including poverty, inadequate school resources, or cultural factors that hinder timely enrollment and progression.

Understanding the significance of over-age students in primary education is crucial. High percentages of over-age students not only indicate inefficiencies in the education system—such as late school entry or high dropout rates—but also reflect broader societal challenges. These may include economic instability, conflict, or health-related barriers that affect families' ability to enroll children at the appropriate age.

In analyzing relationships to other educational metrics, over-age enrollment is often correlated with dropout rates, education quality, and economic factors. Countries with high rates of over-age students typically struggle with higher dropout rates as these students may lose motivation or face additional socio-cultural challenges. Moreover, this indicator can be linked to national education spending; countries investing adequately in education often see fewer over-age students, as better resources and trained educators facilitate more timely educational progress for all age groups.

The World Bank's data from 2019 revealed a shocking landscape concerning over-age male students in primary education. The median value for over-age students across various regions was 6.57%. This figure indicates that in a typical context, approximately 6.57% of male students enrolled in primary education are over the recommended age. When examining the top five areas with the highest rates, we see that Nepal leads at an alarming 24.65%. This number suggests significant barriers that prevent timely school enrollment, which may include socio-economic challenges or inadequate access to quality education.

Following Nepal, Djibouti exhibits a significant over-age rate at 11.45%, reflecting similar underlying issues that warrant concern. While Monaco and Kazakhstan appear on the list with lower rates of 1.69% and 0.76%, respectively, it is worth noting that these countries are nuanced cases. Monaco's low figure may reflect its small population and strong educational support systems, while Kazakhstan's relative standing could suggest disparities in educational access among different regions within the country.

Conversely, the bottom five areas in terms of over-age students challenge the perception that lower percentages always equate to success. As seen, the 0.76% of over-age students in Kazakhstan and the 1.69% in Monaco are significantly lower compared to countries like Nepal and Djibouti. However, one must examine the context surrounding these figures. The data may overlook underreporting, specific demographics, or the quality of education provided. For example, a low over-age percentage might not necessarily mean a high success rate if there are other systemic issues affecting educational quality or access.

Various factors influence the prevalence of over-age students in primary education. Economic variables play a vital role; families in poverty often prioritize immediate work of older children over education, delaying school enrollment. Additionally, cultural factors can impact educational norms—where education may not be emphasized, leading to late entry into schooling. Geographical barriers, such as distance to schools or infrastructural inadequacies, also contribute to students falling behind. Moreover, socio-political instability and conflict can disrupt education systems, deepening the over-age issue.

Addressing the challenges associated with high over-age student rates requires multifaceted strategies. Governments need to invest in early childhood education and awareness campaigns that promote the importance of timely school enrollment. On-the-ground programs focusing on financial assistance for families can lessen the economic burden that prevents children from attending school at the appropriate age. Additionally, community engagement initiatives that seek to shift cultural attitudes toward education can provide long-term solutions to this issue.

Implementing flexible schooling options, such as evening or accelerated learning programs, may also provide pathways for over-age students to catch up with their peers. Countries successful in reducing over-age student percentages often do so by focusing on equal access to education and supporting families economically and socially.

However, it's essential to recognize the flaws in solely focusing on the percentage of over-age students as an indicator of education quality. This data point alone may oversimplify the complex challenges facing educational systems. For instance, it doesn’t capture the progressive needs of the educational journey, such as quality of instruction, engagement with curricula, or support services for at-risk students. While addressing the percentage of over-age students is crucial, a comprehensive approach that considers all factors influencing educational access and quality must inform interventions. Failing to adopt a holistic perspective may lead to misdirected policies and insufficiently addressed barriers to education for all children.

In conclusion, the indicator of over-age male students in primary education provides valuable insights into broader educational challenges. It highlights the need for targeted strategies to ensure timely access and equitable education for all students. By addressing the roots of this issue while considering the context, stakeholders can work towards optimizing education systems globally.

                    
# Install missing packages
import sys
import subprocess

def install(package):
subprocess.check_call([sys.executable, "-m", "pip", "install", package])

# Required packages
for package in ['wbdata', 'country_converter']:
try:
__import__(package)
except ImportError:
install(package)

# Import libraries
import wbdata
import country_converter as coco
from datetime import datetime

# Define World Bank indicator code
dataset_code = 'SE.PRM.OENR.MA.ZS'

# Download data from World Bank API
data = wbdata.get_dataframe({dataset_code: 'value'},
date=(datetime(1960, 1, 1), datetime.today()),
parse_dates=True,
keep_levels=True).reset_index()

# Extract year
data['year'] = data['date'].dt.year

# Convert country names to ISO codes using country_converter
cc = coco.CountryConverter()
data['iso2c'] = cc.convert(names=data['country'], to='ISO2', not_found=None)
data['iso3c'] = cc.convert(names=data['country'], to='ISO3', not_found=None)

# Filter out rows where ISO codes could not be matched — likely not real countries
data = data[data['iso2c'].notna() & data['iso3c'].notna()]

# Sort for calculation
data = data.sort_values(['iso3c', 'year'])

# Calculate YoY absolute and percent change
data['value_change'] = data.groupby('iso3c')['value'].diff()
data['value_change_percent'] = data.groupby('iso3c')['value'].pct_change() * 100

# Calculate ranks (higher GDP per capita = better rank)
data['rank'] = data.groupby('year')['value'].rank(ascending=False, method='dense')

# Calculate rank change from previous year
data['rank_change'] = data.groupby('iso3c')['rank'].diff()

# Select desired columns
final_df = data[['country', 'iso2c', 'iso3c', 'year', 'value',
'value_change', 'value_change_percent', 'rank', 'rank_change']].copy()

# Optional: Add labels as metadata (could be useful for export or UI)
column_labels = {
'country': 'Country name',
'iso2c': 'ISO 2-letter country code',
'iso3c': 'ISO 3-letter country code',
'year': 'Year',
'value': 'GDP per capita (current US$)',
'value_change': 'Year-over-Year change in value',
'value_change_percent': 'Year-over-Year percent change in value',
'rank': 'Country rank by GDP per capita (higher = richer)',
'rank_change': 'Change in rank from previous year'
}

# Display first few rows
print(final_df.head(10))

# Optional: Save to CSV
#final_df.to_csv("gdp_per_capita_cleaned.csv", index=False)
                    
                
                    
# Check and install required packages
required_packages <- c("WDI", "countrycode", "dplyr")

for (pkg in required_packages) {
  if (!requireNamespace(pkg, quietly = TRUE)) {
    install.packages(pkg)
  }
}

# Load the necessary libraries
library(WDI)
library(dplyr)
library(countrycode)

# Define the dataset code (World Bank indicator code)
dataset_code <- 'SE.PRM.OENR.MA.ZS'

# Download data using WDI package
dat <- WDI(indicator = dataset_code)

# Filter only countries using 'is_country' from countrycode
# This uses iso2c to identify whether the entry is a recognized country
dat <- dat %>%
  filter(countrycode(iso2c, origin = 'iso2c', destination = 'country.name', warn = FALSE) %in%
           countrycode::codelist$country.name.en)

# Ensure dataset is ordered by country and year
dat <- dat %>%
  arrange(iso3c, year)

# Rename the dataset_code column to "value" for easier manipulation
dat <- dat %>%
  rename(value = !!dataset_code)

# Calculate year-over-year (YoY) change and percentage change
dat <- dat %>%
  group_by(iso3c) %>%
  mutate(
    value_change = value - lag(value),                              # Absolute change from previous year
    value_change_percent = 100 * (value - lag(value)) / lag(value) # Percent change from previous year
  ) %>%
  ungroup()

# Calculate rank by year (higher value => higher rank)
dat <- dat %>%
  group_by(year) %>%
  mutate(rank = dense_rank(desc(value))) %>% # Rank countries by descending value
  ungroup()

# Calculate rank change (positive = moved up, negative = moved down)
dat <- dat %>%
  group_by(iso3c) %>%
  mutate(rank_change = rank - lag(rank)) %>% # Change in rank compared to previous year
  ungroup()

# Select and reorder final columns
final_data <- dat %>%
  select(
    country,
    iso2c,
    iso3c,
    year,
    value,
    value_change,
    value_change_percent,
    rank,
    rank_change
  )

# Add labels (variable descriptions)
attr(final_data$country, "label") <- "Country name"
attr(final_data$iso2c, "label") <- "ISO 2-letter country code"
attr(final_data$iso3c, "label") <- "ISO 3-letter country code"
attr(final_data$year, "label") <- "Year"
attr(final_data$value, "label") <- "GDP per capita (current US$)"
attr(final_data$value_change, "label") <- "Year-over-Year change in value"
attr(final_data$value_change_percent, "label") <- "Year-over-Year percent change in value"
attr(final_data$rank, "label") <- "Country rank by GDP per capita (higher = richer)"
attr(final_data$rank_change, "label") <- "Change in rank from previous year"

# Print the first few rows of the final dataset
print(head(final_data, 10))