1. INTRODUCTION
highlighting the role of time-series modeling in identifying epidemic waves [14]. Zarikas et al. applied clustering to country-level COVID-19 cases and epidemiological variables to examine similarities in outbreak patterns. Their findings show how clustering can reveal latent patterns in large datasets and support comparisons of national responses [15].
The COVID-19 pandemic has prompted extensive research into clustering algorithms for modeling transmission patterns, country-level heterogeneity, and epidemiological dynamics. Studies have demonstrated the value of unsupervised learning, particularly clustering, for distinguishing country-level patterns and characterizing outbreak severity.
Other methods have also been explored. Mahmoudi et al. used fuzzy clustering to compare COVID-19 spread rates among high-risk countries, accounting for uncertainty and
James and Menzies examined COVID-19 trajectories in the United States during the second surge using chaos theory, overlapping cluster membership [16]. Pasin examined countries in terms of cases and deaths, while Ramadan et al. used multivariate analysis of daily statistics to track changing pandemic indicators [17, 18]. Together, these studies support using multiple variables to represent the scale and temporal development of the pandemic.
Time-series clustering has been used to characterize how epidemic curves evolve across countries and how outbreak peaks synchronize [19]. Research on pandemic responses has also emphasized the influence of democracy, capacity, coercion, and political institutions on intervention strategies and epidemiological outcomes [20]. Global preparedness measures, including the Global Health Security Index and the epidemic preparedness index, can complement outcomebased clustering by describing health-system readiness [21, 22].
Clinical and epidemiological evidence provides further context for interpreting clusters. Reviews of COVID-19 pathophysiology, transmission, diagnosis, and treatment, together with studies of hospitalized patients and excess mortality, help explain differences in mortality burden among country groups [23, 24, 25]. Overall, clustering offers an unsupervised means of identifying similarities and contrasts in pandemic impact, while preparedness and clinical indicators can improve interpretation of the resulting groups.
2. RELATED WORK
The COVID-19 pandemic has driven sustained investigation of clustering methods for identifying patterns of spread, national-level heterogeneity, and epidemiological dynamics. Prior work has shown that unsupervised learning can distinguish country-level trends and help characterize outbreak severity.
James and Menzies analyzed the second COVID-19 surge in the United States through chaos theory, emphasizing the usefulness of time-series modeling for identifying epidemic waves. Zarikas et al. grouped countries using COVID-19 case data and epidemiological variables to study similarities in outbreak trends and national responses [14, 15].
Fuzzy clustering has been used to compare transmission rates in high-risk countries while representing uncertainty and overlapping cluster membership [16]. Country comparisons based on deaths and cases, as well as multivariate analysis of daily statistics, have also been used to examine international mortality, morbidity, and changing pandemic indicators [17, 18].
For temporal analysis, a cluster-based dual-evolution model has been applied to multivariate COVID-19 time series to describe epidemic-curve development and the synchronization of outbreak peaks [19]. Other work has examined how governance, national capacity, and coercion shape pandemic responses [20]. The Global Health Security Index and epidemic preparedness measures provide system-readiness indicators that can be considered alongside epidemiological outcomes [21, 22].
Clinical studies further inform interpretation of country clusters. Research on COVID-19 pathophysiology and transmission, patient characteristics and outcomes, and pandemicassociated excess mortality provides context for differences in disease burden across groups [23, 24, 25]. Taken together, prior methods—from fuzzy clustering to time-series analysis—complement traditional epidemiological models by revealing patterns of similarity and contrast. Incorporating preparedness and clinical indicators can make cluster results more interpretable and support further study of global health vulnerabilities and strengths.
3. DATA AND METHODOLOGY
3.1 Dataset
The dataset used in this analysis is a Kaggle-distributed copy of Worldometer’s country-level cumulative COVID-19 tracker, whose final update was April 13, 2024 [26]. It contains 231 reporting entries: 229 countries and territories, plus the Diamond Princess and MS Zaandam cruise ships. Its 21 attributes represent absolute and relative pandemic measures, including total confirmed cases, deaths, recoveries, active cases, serious or critical cases, and testing numbers. To support comparisons among countries with different population sizes, the dataset also includes cases, deaths, active cases, and tests per million people, as well as population and continent.
Preprocessing was required to address missing values, normalize numeric attributes, and correct formatting inconsistencies. Figure 1 summarizes the procedure. In the raw Worldometer table, string-formatted numbers, commas, and special characters were cleaned, and variables were converted to numeric form. Missing values were imputed using the median. Feature selection then retained nine epidemiological indicators: total cases, deaths, recoveries, active cases, cases per million, deaths per million, active cases per million, tests per million, and population.
3.2 Hierarchical Clustering
Hierarchical clustering is an unsupervised machine-learning technique that organizes observations into nested clusters according to similarity. Let the dataset be defined as
where n is the number of countries or samples and m is the number of epidemiological variables. The algorithm starts with each observation in its own cluster and sequentially merges clusters until all observations belong to a single cluster. Its aim is to minimize within-cluster distance and maximize separation between clusters.
The Euclidean distance between two observations is
(xif −xj f )2. (2) d(xi,x j) =
∑ f=1
This is a commonly used measure for epidemiological data. Alternatives include the Manhattan distance, m ∑ f=1
d(xi,x j) = and cosine similarity,
Linkage criteria define how distances between clusters are measured. Single linkage uses the minimum pairwise distance,
whereas complete linkage uses the maximum:
Average linkage takes the mean of the pairwise distances, d(A,B) = 1 |A||B| ∑
balancing the extremes of single and complete linkage. Ward’s criterion instead minimizes the increase in withincluster variance:
∆(A,B) = |A||B| |A|+|B|∥¯xA −¯xB∥2
where ¯xA and ¯xB are the cluster centroids.
The sequence of merges is recorded in a dendrogram, whose branch heights correspond to linkage distances. A fixed set of k clusters can be obtained by cutting the dendrogram at threshold τ:
for distinct clusters [27, 28, 29, 30, 31, 32, 33, 34].
Figure 2 shows the Ward-linkage dendrogram for the global
COVID-19 data. Its leaves represent individual countries, and the vertical links indicate the distances at which clusters merge. Short links connect countries with similar epidemiological characteristics, while taller links connect more dissimilar groups. Natural break points in the tree provide a basis for selecting the number of clusters.
4. RESULTS
The analysis was conducted in Python. Pandas, NumPy, and scikit-learn were used for preprocessing, normalization, and clustering; matplotlib and seaborn were used to produce dendrograms, correlation heatmaps, and cluster profiles.
The PCA projection of the first two components is shown in Figure 3. Four clusters are distinguished by color. Cluster 0 (approximately 50% of countries) and Cluster 2 (approximately 45%) account for most observations, while Clusters 1 and 3 (approximately 1% each) appear as extreme outliers.
Figure 4 shows the first and third principal components. Clusters 0 and 2 again contain most countries, whereas Clusters 1 and 3, together comprising less than 2% of the dataset, appear as outliers. This pattern indicates that the clustering is stable across these dimensions.
Figure 5 compares principal components 2 and 3. Clusters 0 and 2 together include about 95% of countries and form the dense center of the projection. The remaining observations belong to Clusters 1 and 3, representing uncommon pandemic profiles.
Figure 6 presents boxplots of seven COVID-19 indicators
across the four clusters. Cluster 1 (approximately 1% of countries) has exceptionally high total cases, reaching tens of millions. Clusters 0 and 2 contain most countries and generally have lower case counts, while Cluster 3 represents an intermediate but consistent profile. Total deaths follow a similar pattern: despite its small size, Cluster 1 includes countries with more than one million fatalities, whereas Clusters 0 and 2 have lower median counts and varied pandemic effects.
Cluster 1 also has the greatest active-case burden, with many countries exceeding one million active cases. The cases-permillion distributions for Clusters 0 and 2 have broad ranges. Cluster 1 has the highest deaths per million, while Cluster 0 has a broader, more scattered distribution. Testing per million is most dispersed in Cluster 0, including countries with more than 20 million tests per million people; Cluster 2 has more moderate and consistent testing. The population plot highlights the exceptionally large population represented in Cluster 3, while most countries in Clusters 0 and 2 have more moderate population sizes.
Figure 7 quantifies cluster membership. Cluster 0 contains approximately 50% of countries and Cluster 2 approximately 45%, while Clusters 1 and 3 each contain fewer than 2%. Thus, the global dataset is dominated by two epidemiological patterns, with a small number of countries differing substantially.
Figure 8 shows normalized mean indicator values across the
four clusters, with values ranging from 0 (minimum) to 1 (maximum). Cluster 0 has normalized values of 1.0 for cases per million, deaths per million, and tests per million, while its absolute case, death, and recovery counts are low (approximately 0.05), indicating smaller countries with high population-adjusted impact. Cluster 1 has the highest normalized values for most absolute measures, including cases, deaths, recoveries, and active cases; cases per million are 0.72 and deaths per million are 1.0, while testing intensity is moderate at 0.46. Cluster 2 has values close to zero across indicators, reflecting low reported impact. Cluster 3 has relatively high normalized case (0.60) and death (0.55) counts and the highest normalized population (1.0), indicating a highly populated country with substantial absolute counts but more contained per-capita impact.
5. CONCLUSION
This study applied Ward-linkage hierarchical clustering to global COVID-19 data from Worldometer’s tracker, last updated April 13, 2024, to identify country-level patterns of pandemic impact. Preprocessing, normalization, and clustering yielded four groups representing different levels of case burden, mortality, testing intensity, and demographic characteristics. The dendrogram revealed natural splits in the data, and PCA projections showed separation among clusters. Cluster validity scores were a Silhouette measure of 38.5%, a Davies–Bouldin Index of 0.87, and a Calinski–Harabasz Index of 77.6.
Cluster profiling identified two large groups: Cluster 0, containing approximately 50% of countries, and Cluster 2, containing approximately 45%. Clusters 1 and 3, together representing approximately 2% of countries, comprised outliers with unusually high case counts, testing intensity, or population characteristics. Correlation analysis indicated strong relationships among deaths, total cases, and recoveries, while per-capita measures aligned closely with mortality rates.