• About
  • Advertise
  • Privacy & Policy
  • Contact
Thursday, January 1, 2026
  • Login
  • Home
    • Home – Layout 1
    • Home – Layout 2
    • Home – Layout 3
    • Home – Layout 4
    • Home – Layout 5
    • Home – Layout 6
  • News
    • All
    • Business
    • Politics
    • Science
    • World
    Hillary Clinton in white pantsuit for Trump inauguration

    Hillary Clinton in white pantsuit for Trump inauguration

    Amazon has 143 billion reasons to keep adding more perks to Prime

    Amazon has 143 billion reasons to keep adding more perks to Prime

    Shooting More than 40 Years of New York’s Halloween Parade

    Shooting More than 40 Years of New York’s Halloween Parade

    These Are the 5 Big Tech Stories to Watch in 2017

    These Are the 5 Big Tech Stories to Watch in 2017

    Why Millennials Need to Save Twice as Much as Boomers Did

    Why Millennials Need to Save Twice as Much as Boomers Did

    Doctors take inspiration from online dating to build organ transplant AI

    Doctors take inspiration from online dating to build organ transplant AI

    Trending Tags

    • Trump Inauguration
    • United Stated
    • White House
    • Market Stories
    • Election Results
  • Tech
    • All
    • Apps
    • Gadget
    • Mobile
    • Startup
    The Legend of Zelda: Breath of the Wild gameplay on the Nintendo Switch

    The Legend of Zelda: Breath of the Wild gameplay on the Nintendo Switch

    Shadow Tactics: Blades of the Shogun Review

    Shadow Tactics: Blades of the Shogun Review

    macOS Sierra review: Mac users get a modest update this year

    macOS Sierra review: Mac users get a modest update this year

    Hands on: Samsung Galaxy A5 2017 review

    Hands on: Samsung Galaxy A5 2017 review

    The Last Guardian Playstation 4 Game review

    The Last Guardian Playstation 4 Game review

    These Are the 5 Big Tech Stories to Watch in 2017

    These Are the 5 Big Tech Stories to Watch in 2017

    Trending Tags

    • Nintendo Switch
    • CES 2017
    • Playstation 4 Pro
    • Mark Zuckerberg
  • Entertainment
    • All
    • Gaming
    • Movie
    • Music
    • Sports
    The Legend of Zelda: Breath of the Wild gameplay on the Nintendo Switch

    The Legend of Zelda: Breath of the Wild gameplay on the Nintendo Switch

    macOS Sierra review: Mac users get a modest update this year

    macOS Sierra review: Mac users get a modest update this year

    Hands on: Samsung Galaxy A5 2017 review

    Hands on: Samsung Galaxy A5 2017 review

    Heroes of the Storm Global Championship 2017 starts tomorrow, here’s what you need to know

    Heroes of the Storm Global Championship 2017 starts tomorrow, here’s what you need to know

    Harnessing the power of VR with Power Rangers and Snapdragon 835

    Harnessing the power of VR with Power Rangers and Snapdragon 835

    So you want to be a startup investor? Here are things you should know

    So you want to be a startup investor? Here are things you should know

  • Lifestyle
    • All
    • Fashion
    • Food
    • Health
    • Travel
    Shooting More than 40 Years of New York’s Halloween Parade

    Shooting More than 40 Years of New York’s Halloween Parade

    Heroes of the Storm Global Championship 2017 starts tomorrow, here’s what you need to know

    Heroes of the Storm Global Championship 2017 starts tomorrow, here’s what you need to know

    Why Millennials Need to Save Twice as Much as Boomers Did

    Why Millennials Need to Save Twice as Much as Boomers Did

    Doctors take inspiration from online dating to build organ transplant AI

    Doctors take inspiration from online dating to build organ transplant AI

    How couples can solve lighting disagreements for good

    How couples can solve lighting disagreements for good

    Ducati launch: Lorenzo and Dovizioso’s Desmosedici

    Ducati launch: Lorenzo and Dovizioso’s Desmosedici

    Trending Tags

    • Golden Globes
    • Game of Thrones
    • MotoGP 2017
    • eSports
    • Fashion Week
  • Review
    The Legend of Zelda: Breath of the Wild gameplay on the Nintendo Switch

    The Legend of Zelda: Breath of the Wild gameplay on the Nintendo Switch

    Shadow Tactics: Blades of the Shogun Review

    Shadow Tactics: Blades of the Shogun Review

    macOS Sierra review: Mac users get a modest update this year

    macOS Sierra review: Mac users get a modest update this year

    Hands on: Samsung Galaxy A5 2017 review

    Hands on: Samsung Galaxy A5 2017 review

    The Last Guardian Playstation 4 Game review

    The Last Guardian Playstation 4 Game review

    Intel Core i7-7700K ‘Kaby Lake’ review

    Intel Core i7-7700K ‘Kaby Lake’ review

No Result
View All Result
Ai News
Advertisement
  • Home
    • Home – Layout 1
    • Home – Layout 2
    • Home – Layout 3
    • Home – Layout 4
    • Home – Layout 5
    • Home – Layout 6
  • News
    • All
    • Business
    • Politics
    • Science
    • World
    Hillary Clinton in white pantsuit for Trump inauguration

    Hillary Clinton in white pantsuit for Trump inauguration

    Amazon has 143 billion reasons to keep adding more perks to Prime

    Amazon has 143 billion reasons to keep adding more perks to Prime

    Shooting More than 40 Years of New York’s Halloween Parade

    Shooting More than 40 Years of New York’s Halloween Parade

    These Are the 5 Big Tech Stories to Watch in 2017

    These Are the 5 Big Tech Stories to Watch in 2017

    Why Millennials Need to Save Twice as Much as Boomers Did

    Why Millennials Need to Save Twice as Much as Boomers Did

    Doctors take inspiration from online dating to build organ transplant AI

    Doctors take inspiration from online dating to build organ transplant AI

    Trending Tags

    • Trump Inauguration
    • United Stated
    • White House
    • Market Stories
    • Election Results
  • Tech
    • All
    • Apps
    • Gadget
    • Mobile
    • Startup
    The Legend of Zelda: Breath of the Wild gameplay on the Nintendo Switch

    The Legend of Zelda: Breath of the Wild gameplay on the Nintendo Switch

    Shadow Tactics: Blades of the Shogun Review

    Shadow Tactics: Blades of the Shogun Review

    macOS Sierra review: Mac users get a modest update this year

    macOS Sierra review: Mac users get a modest update this year

    Hands on: Samsung Galaxy A5 2017 review

    Hands on: Samsung Galaxy A5 2017 review

    The Last Guardian Playstation 4 Game review

    The Last Guardian Playstation 4 Game review

    These Are the 5 Big Tech Stories to Watch in 2017

    These Are the 5 Big Tech Stories to Watch in 2017

    Trending Tags

    • Nintendo Switch
    • CES 2017
    • Playstation 4 Pro
    • Mark Zuckerberg
  • Entertainment
    • All
    • Gaming
    • Movie
    • Music
    • Sports
    The Legend of Zelda: Breath of the Wild gameplay on the Nintendo Switch

    The Legend of Zelda: Breath of the Wild gameplay on the Nintendo Switch

    macOS Sierra review: Mac users get a modest update this year

    macOS Sierra review: Mac users get a modest update this year

    Hands on: Samsung Galaxy A5 2017 review

    Hands on: Samsung Galaxy A5 2017 review

    Heroes of the Storm Global Championship 2017 starts tomorrow, here’s what you need to know

    Heroes of the Storm Global Championship 2017 starts tomorrow, here’s what you need to know

    Harnessing the power of VR with Power Rangers and Snapdragon 835

    Harnessing the power of VR with Power Rangers and Snapdragon 835

    So you want to be a startup investor? Here are things you should know

    So you want to be a startup investor? Here are things you should know

  • Lifestyle
    • All
    • Fashion
    • Food
    • Health
    • Travel
    Shooting More than 40 Years of New York’s Halloween Parade

    Shooting More than 40 Years of New York’s Halloween Parade

    Heroes of the Storm Global Championship 2017 starts tomorrow, here’s what you need to know

    Heroes of the Storm Global Championship 2017 starts tomorrow, here’s what you need to know

    Why Millennials Need to Save Twice as Much as Boomers Did

    Why Millennials Need to Save Twice as Much as Boomers Did

    Doctors take inspiration from online dating to build organ transplant AI

    Doctors take inspiration from online dating to build organ transplant AI

    How couples can solve lighting disagreements for good

    How couples can solve lighting disagreements for good

    Ducati launch: Lorenzo and Dovizioso’s Desmosedici

    Ducati launch: Lorenzo and Dovizioso’s Desmosedici

    Trending Tags

    • Golden Globes
    • Game of Thrones
    • MotoGP 2017
    • eSports
    • Fashion Week
  • Review
    The Legend of Zelda: Breath of the Wild gameplay on the Nintendo Switch

    The Legend of Zelda: Breath of the Wild gameplay on the Nintendo Switch

    Shadow Tactics: Blades of the Shogun Review

    Shadow Tactics: Blades of the Shogun Review

    macOS Sierra review: Mac users get a modest update this year

    macOS Sierra review: Mac users get a modest update this year

    Hands on: Samsung Galaxy A5 2017 review

    Hands on: Samsung Galaxy A5 2017 review

    The Last Guardian Playstation 4 Game review

    The Last Guardian Playstation 4 Game review

    Intel Core i7-7700K ‘Kaby Lake’ review

    Intel Core i7-7700K ‘Kaby Lake’ review

No Result
View All Result
Ai News
No Result
View All Result
Home Machine Learning

The Machine Learning “Advent Calendar” Day 10: DBSCAN in Excel

AiNEWS2025 by AiNEWS2025
2025-12-11
in Machine Learning
0
The Machine Learning “Advent Calendar” Day 10: DBSCAN in Excel
0
SHARES
0
VIEWS
Share on FacebookShare on Twitter


Here we are on Day 10 of my Machine Learning “Advent Calendar”. I would like to thank you for your support.

I have been building these Google Sheet files for years. They evolved little by little. But when it is time to publish them, I always need hours to reorganize everything, clean the layout, and make them pleasant to read.

Today, we move to DBSCAN.

DBSCAN Does Not Learn a Parametric Model

Just like LOF, DBSCAN is not a parametric model. There is no formula to store, no rules, no centroids, and nothing compact to reuse later.

We must keep the whole dataset because the density structure depends on all points.

Its full name is Density-Based Spatial Clustering of Applications with Noise.

But careful: this “density” is not a Gaussian density.

It is a count-based notion of density. Just “how many neighbors live close to me”.

Why DBSCAN Is Special

As its name indicates, DBSCAN does two things at the same time:

  • it finds clusters
  • it marks anomalies (the points that do not belong to any cluster)

This is exactly why I present the algorithms in this order:

  • k-means and GMM are clustering models. They output a compact object: centroids for k-means, means and variances for GMM.
  • Isolation Forest and LOF are pure anomaly detection models. Their only goal is to find unusual points.
  • DBSCAN sits in between. It does both clustering and anomaly detection, based only on the notion of neighborhood density.

A Tiny Dataset to Keep Things Intuitive

We stay with the same tiny dataset that we used for LOF: 1, 2, 3, 7, 8, 12

If you look at these numbers, you already see two compact groups:
one around 1–2–3, another around 7–8, and 12 living alone.

DBSCAN captures exactly this intuition.

Summary in 3 Steps

DBSCAN asks three simple questions for each point:

  1. How many neighbors do you have within a small radius (eps)?
  2. Do you have enough neighbors to become a Core point (minPts)?
  3. Once we know the Core points, to which connected group do you belong?

Here is the summary of the DBSCAN algorithm in 3 steps:

DBSCAN in excel – all images by author

Let us begin step by step.

DBSCAN in 3 steps

Now that we understand the idea of density and neighborhoods, DBSCAN becomes very easy to describe.
Everything the algorithm does fits into three simple steps.

Step 1 – Count the neighbors

The goal is to check how many neighbors each point has.

We take a small radius called eps.

For each point, we look at all other points and mark those whose distance is less than eps.
These are the neighbors.

This gives us the first idea of density:
a point with many neighbors is in a dense region,
a point with few neighbors lives in a sparse region.

For a 1-dimensional toy example like ours, a common choice is:
eps = 2

We draw a little interval of radius 2 around each point.

Why is it called eps?

The name eps comes from the Greek letter ε (epsilon), which is traditionally used in mathematics to represent a small quantity or a small radius around a point.
So in DBSCAN, eps is literally “the small neighborhood radius”.

It answers the question:
How far do we look around each point?

So in Excel, the first step is to compute the pairwise distance matrix, then count how many neighbors each point has within eps.

Step 2 – Core Points and Density Connectivity

Now that we know the neighbors from Step 1, we apply minPts to decide which points are Core.

minPts means here minimum number of points.

It is the smallest number of neighbors a point must have (inside the eps radius) to be considered a Core point.

A point is Core if it has at least minPts neighbors inside eps.
Otherwise, it may become Border or Noise.

With eps = 2 and minPts = 2, we have 12 that is not Core.

Once the Core points are known, we simply check which points are density-reachable from them. If a point can be reached by moving from one Core point to another within eps, it belongs to the same group.

In Excel, we can represent this as a simple connectivity table that shows which points are linked through Core neighbors.

This connectivity is what DBSCAN uses to form clusters in Step 3.

Step 3 – Assign cluster labels

The goal is to turn connectivity into actual clusters.

Once the connectivity matrix is ready, the clusters appear naturally.
DBSCAN simply groups all connected points together.

To give each group a simple and reproducible name, we use a very intuitive rule:

The cluster label is the smallest point in the connected group.

For example:

  • Group {1, 2, 3} becomes cluster 1
  • Group {7, 8} becomes cluster 7
  • A point like 12 with no Core neighbors becomes Noise

This is exactly what we will display in Excel using formulas.

Final thoughts

DBSCAN is perfect to teach the idea of local density.

There is no probability, no Gaussian formula, no estimation step.
Just distances, neighbors, and a small radius.

But this simplicity also limits it.
Because DBSCAN uses one fixed radius for everyone, it cannot adapt when the dataset contains clusters of different scales.

HDBSCAN keeps the same intuition, but looks at all radii and keeps what remains stable.
It is far more robust, and much closer to how humans naturally see clusters.

With DBSCAN, we have reached a natural moment to step back and summarize the unsupervised models we have explored so far, as well as a few others we have not covered.

It is a good opportunity to draw a small map that links these algorithms together and shows where each of them sits in the broader landscape.

  • Distance–based models
    K-means, K-medoids, and hierarchical clustering (HAC) work by comparing distances between points or between groups.
  • Density–based models
    Mean Shift and Gaussian Mixture Models (GMM) estimate a smooth density and extract clusters from its structure.
  • Neighborhood–based models
    DBSCAN, OPTICS, HDBSCAN, and LOF define clusters and anomalies from local connectivity rather than global distance.
  • Graph–based models
    Spectral clustering, Louvain, and Leiden rely on structure inside similarity graphs.

Each group reflects a different philosophy of what a “cluster” is.
Your choice of algorithm often depends less on theory and more on the shape of the data, the scale of its densities, and the kinds of structures you expect to find.

Here is how these methods connect to each other:

  • K-means generalizes into GMM when you replace hard assignments with probabilistic densities.
  • DBSCAN generalizes into OPTICS when you remove the need for a single eps value.
  • OPTICS leads naturally to HDBSCAN, which turns density connectivity into a stable hierarchy.
  • HAC and Spectral clustering both build clusters from pairwise distances, but Spectral adds a graph-based view.
  • LOF uses the same neighborhoods as DBSCAN, but only for anomaly detection.

There are many more models, but this gives a sense of the landscape and where DBSCAN fits inside it.

Distance based unsupervised learning landscape – image by author

Tomorrow, we will continue the Advent Calendar with models that are more “classic” and widely used in everyday machine learning.
Thank you for following the journey so far, and see you tomorrow.

Source link

#Machine #Learning #Advent #Calendar #Day #DBSCAN #Excel

Tags: algorithmsartificial intelligenceClusteringDbscanExcel
Previous Post

NASA just lost contact with a Mars orbiter, and will soon lose another one

Next Post

AI in Higher Education: A Guide for Teachers

AiNEWS2025

AiNEWS2025

Next Post
AI in Higher Education: A Guide for Teachers

AI in Higher Education: A Guide for Teachers

Stay Connected test

  • 23.9k Followers
  • 99 Subscribers
  • Trending
  • Comments
  • Latest
A tiny new open source AI model performs as well as powerful big ones

A tiny new open source AI model performs as well as powerful big ones

0
Water Cooler Small Talk: The Birthday Paradox 🎂🎉 | by Maria Mouschoutzi, PhD | Sep, 2024

Water Cooler Small Talk: The Birthday Paradox 🎂🎉 | by Maria Mouschoutzi, PhD | Sep, 2024

0
Ghost of Yōtei: The acclaimed Ghost of Tsushima is getting a sequel

Ghost of Yōtei: The acclaimed Ghost of Tsushima is getting a sequel

0
Best Headphones for Working Out (2024): Bose, Shokz, JLab

Best Headphones for Working Out (2024): Bose, Shokz, JLab

0
MIT engineers design an aerial microrobot that can fly as fast as a bumblebee

MIT engineers design an aerial microrobot that can fly as fast as a bumblebee

2025-12-31
Production-Ready LLMs Made Simple with the NeMo Agent Toolkit

Production-Ready LLMs Made Simple with the NeMo Agent Toolkit

2025-12-31
Here we go again: Retiring coal plant forced to stay open by Trump Admin

Here we go again: Retiring coal plant forced to stay open by Trump Admin

2025-12-31
Why inventing new emotions feels so good

Why inventing new emotions feels so good

2025-12-31

Recent News

MIT engineers design an aerial microrobot that can fly as fast as a bumblebee

MIT engineers design an aerial microrobot that can fly as fast as a bumblebee

2025-12-31
Production-Ready LLMs Made Simple with the NeMo Agent Toolkit

Production-Ready LLMs Made Simple with the NeMo Agent Toolkit

2025-12-31
Here we go again: Retiring coal plant forced to stay open by Trump Admin

Here we go again: Retiring coal plant forced to stay open by Trump Admin

2025-12-31
Why inventing new emotions feels so good

Why inventing new emotions feels so good

2025-12-31
Footer logo

We bring you the best Premium WordPress Themes that perfect for news, magazine, personal blog, etc. Check our landing page for details.

Follow Us

Browse by Category

  • AI & Cloud Computing
  • AI & Cybersecurity
  • AI & Sentiment Analysis
  • AI Applications
  • AI Ethics
  • AI Future Predictions
  • AI in Education
  • AI in Fintech
  • AI in Gaming
  • AI in Healthcare
  • AI in Startups
  • AI Innovations
  • AI News
  • AI Research
  • AI Tools & Automation
  • Apps
  • AR/VR & AI
  • Business
  • Deep Learning
  • Emerging Technologies
  • Entertainment
  • Fashion
  • Food
  • Gadget
  • Gaming
  • Health
  • Lifestyle
  • Machine Learning
  • Mobile
  • Movie
  • Music
  • News
  • Politics
  • Review
  • Robotics & Smart Systems
  • Science
  • Sports
  • Startup
  • Tech
  • Travel
  • World

Recent News

MIT engineers design an aerial microrobot that can fly as fast as a bumblebee

MIT engineers design an aerial microrobot that can fly as fast as a bumblebee

2025-12-31
Production-Ready LLMs Made Simple with the NeMo Agent Toolkit

Production-Ready LLMs Made Simple with the NeMo Agent Toolkit

2025-12-31
  • About
  • Advertise
  • Privacy & Policy
  • Contact

© 2026 JNews - Premium WordPress news & magazine theme by Jegtheme.

Welcome Back!

Login to your account below

Forgotten Password?

Retrieve your password

Please enter your username or email address to reset your password.

Log In
No Result
View All Result

© 2026 JNews - Premium WordPress news & magazine theme by Jegtheme.