Memuat
Memuat
DBSCAN for Public Health and Epidemiology
0 views
Apply DBSCAN to synthetic data to cluster districts by immunisation coverage and poverty rate and interpret each group's characteristics. DBSCAN groups points by density, so it finds arbitrarily shaped clusters and flags noise. It suits spatial data or data with outliers and non-spherical clusters.

Apply DBSCAN to synthetic data to cluster districts by immunisation coverage and poverty rate and interpret each group's characteristics.
| Role | Variable | Unit |
|---|---|---|
| Main | District | - |
| Supporting 1 | Immunisation coverage | % |
| Supporting 2 | Poverty rate | % |
DBSCAN (eps 0.31, min_samples 5) finds 2 arbitrarily shaped clusters on District and Immunisation coverage, with 6.7% of points flagged as noise.
Computed from illustrative synthetic data, not from a real study.
DBSCAN groups points by density, so it finds arbitrarily shaped clusters and flags noise. It suits spatial data or data with outliers and non-spherical clusters.
Report eps, min_samples, number of clusters, and noise percentage, then discuss parameter sensitivity. Compare with K-Means to show the advantage on irregular cluster shapes.
A short starting script with this project's variable names. The delivered version is adapted to your data and fully commented.
import numpy as np
import matplotlib.pyplot as plt
from sklearn.datasets import make_moons
from sklearn.cluster import DBSCAN
from sklearn.neighbors import NearestNeighbors
from sklearn.preprocessing import StandardScaler
X, _ = make_moons(n_samples=400, noise=0.07, random_state=17)
X = StandardScaler().fit_transform(X)
immunisation_coverage = X[:, 0]
poverty_rate = X[:, 1]
k = 5
dist, _ = NearestNeighbors(n_neighbors=k).fit(X).kneighbors(X)
kdist = np.sort(dist[:, -1])
db = DBSCAN(eps=0.25, min_samples=k).fit(X)
district = db.labels_
n_clusters = len(set(district)) - (1 if -1 in district else 0)
print("Clusters:", n_clusters)
print("Noise points:", int((district == -1).sum()), "of", len(district))
fig, ax = plt.subplots(1, 2, figsize=(10, 4))
ax[0].plot(kdist); ax[0].set_title("k-distance plot"); ax[0].set_ylabel("distance")
ax[1].scatter(immunisation_coverage, poverty_rate, c=district, cmap="viridis", s=15)
ax[1].set_title("DBSCAN (noise = -1)")
plt.tight_layout()
plt.show()Choose how much help you need. Each higher package includes everything in the lower ones. Prices exclude 11% VAT.
Package 1
US$22
excl. 11% VAT
Duration: 5 working days
Output: Python files + result figures
Deliverables
Package 2 · most chosen
US$66
excl. 11% VAT
Duration: 9 working days
Output: Code + analysis + interpretation notes
Includes all of Package 1, plus
Package 3
US$144
excl. 11% VAT
Duration: 14-17 working days
Output: Code + analysis + guidance until ready to present
Includes all of Packages 1 & 2, plus
Yes. DBSCAN is commonly used at this level in Public Health and Epidemiology. We adapt the analysis to your research question, your own data and your supervisor's requirements.
No. The sheet is computed from illustrative synthetic data so you can see the kind of output Python gives. For your order we run the same method on your own data.
That is the point of the packages. Every script is commented, and Package 3 includes two coaching sessions plus practice questions so you can explain the method and the results at your seminar and defence.
Each project has three packages: Package 1 (code and explanation) US$22, Package 2 (your data analysis and interpretation) US$66 and Package 3 (full guidance) US$144, excluding 11% VAT. Larger datasets, extra methods or tight deadlines adjust the quote after a short consultation.
The result sheet uses illustrative synthetic data. Python is a trademark of the Python Software Foundation.
Back to Python portfolio