<s>
Density-based	O
spatial	O
clustering	O
of	O
applications	O
with	O
noise	O
(	O
DBSCAN	B-Algorithm
)	O
is	O
a	O
data	B-Algorithm
clustering	I-Algorithm
algorithm	O
proposed	O
by	O
Martin	O
Ester	O
,	O
Hans-Peter	O
Kriegel	O
,	O
Jörg	O
Sander	O
and	O
Xiaowei	O
Xu	O
in	O
1996	O
.	O
</s>
<s>
It	O
is	O
a	O
density-based	O
clustering	O
non-parametric	O
algorithm	O
:	O
given	O
a	O
set	O
of	O
points	O
in	O
some	O
space	O
,	O
it	O
groups	O
together	O
points	O
that	O
are	O
closely	O
packed	O
together	O
(	O
points	O
with	O
many	O
nearby	B-Algorithm
neighbors	I-Algorithm
)	O
,	O
marking	O
as	O
outliers	B-Algorithm
points	O
that	O
lie	O
alone	O
in	O
low-density	O
regions	O
(	O
whose	O
nearest	O
neighbors	O
are	O
too	O
far	O
away	O
)	O
.	O
</s>
<s>
DBSCAN	B-Algorithm
is	O
one	O
of	O
the	O
most	O
common	O
clustering	B-Algorithm
algorithms	I-Algorithm
and	O
also	O
most	O
cited	O
in	O
scientific	O
literature	O
.	O
</s>
<s>
In	O
2014	O
,	O
the	O
algorithm	O
was	O
awarded	O
the	O
test	O
of	O
time	O
award	O
(	O
an	O
award	O
given	O
to	O
algorithms	O
which	O
have	O
received	O
substantial	O
attention	O
in	O
theory	O
and	O
practice	O
)	O
at	O
the	O
leading	O
data	O
mining	O
conference	O
,	O
ACM	B-Operating_System
SIGKDD	I-Operating_System
.	O
</s>
<s>
,	O
the	O
follow-up	O
paper	O
"	O
DBSCAN	B-Algorithm
Revisited	O
,	O
Revisited	O
:	O
Why	O
and	O
How	O
You	O
Should	O
(	O
Still	O
)	O
Use	O
DBSCAN	B-Algorithm
"	O
appears	O
in	O
the	O
list	O
of	O
the	O
8	O
most	O
downloaded	O
articles	O
of	O
the	O
prestigious	O
ACM	O
Transactions	O
on	O
Database	O
Systems	O
(	O
TODS	O
)	O
journal	O
.	O
</s>
<s>
DBSCAN	B-Algorithm
has	O
a	O
worst-case	O
of	O
O(n² )	O
,	O
and	O
the	O
database-oriented	O
range-query	O
formulation	O
of	O
DBSCAN	B-Algorithm
allows	O
for	O
index	O
acceleration	O
.	O
</s>
<s>
For	O
the	O
purpose	O
of	O
DBSCAN	B-Algorithm
clustering	O
,	O
the	O
points	O
are	O
classified	O
as	O
core	O
points	O
,	O
(	O
directly	O
-	O
)	O
reachable	O
points	O
and	O
outliers	B-Algorithm
,	O
as	O
follows	O
:	O
</s>
<s>
All	O
points	O
not	O
reachable	O
from	O
any	O
other	O
point	O
are	O
outliers	B-Algorithm
or	O
noise	O
points	O
.	O
</s>
<s>
Therefore	O
,	O
a	O
further	O
notion	O
of	O
connectedness	O
is	O
needed	O
to	O
formally	O
define	O
the	O
extent	O
of	O
the	O
clusters	O
found	O
by	O
DBSCAN	B-Algorithm
.	O
</s>
<s>
DBSCAN	B-Algorithm
requires	O
two	O
parameters	O
:	O
ε	O
(	O
eps	O
)	O
and	O
the	O
minimum	O
number	O
of	O
points	O
required	O
to	O
form	O
a	O
dense	O
region	O
(	O
)	O
.	O
</s>
<s>
DBSCAN	B-Algorithm
can	O
be	O
used	O
with	O
any	O
distance	O
function	O
(	O
as	O
well	O
as	O
similarity	O
functions	O
or	O
other	O
predicates	O
)	O
.	O
</s>
<s>
The	O
algorithm	O
can	O
be	O
expressed	O
in	O
pseudocode	B-Language
as	O
follows	O
:	O
</s>
<s>
The	O
DBSCAN	B-Algorithm
algorithm	O
can	O
be	O
abstracted	O
into	O
the	O
following	O
steps	O
:	O
</s>
<s>
The	O
original	O
DBSCAN	B-Algorithm
algorithm	O
does	O
not	O
require	O
this	O
by	O
performing	O
these	O
steps	O
for	O
one	O
point	O
at	O
a	O
time	O
.	O
</s>
<s>
DBSCAN	B-Algorithm
visits	O
each	O
point	O
of	O
the	O
database	O
,	O
possibly	O
multiple	O
times	O
(	O
e.g.	O
,	O
as	O
candidates	O
to	O
different	O
clusters	O
)	O
.	O
</s>
<s>
DBSCAN	B-Algorithm
executes	O
exactly	O
one	O
such	O
query	O
for	O
each	O
point	O
,	O
and	O
if	O
an	O
indexing	O
structure	O
is	O
used	O
that	O
executes	O
a	O
neighborhood	B-Algorithm
query	I-Algorithm
in	O
,	O
an	O
overall	O
average	O
runtime	O
complexity	O
of	O
is	O
obtained	O
(	O
if	O
parameter	O
is	O
chosen	O
in	O
a	O
meaningful	O
way	O
,	O
i.e.	O
</s>
<s>
The	O
=	O
-sized	O
upper	O
triangle	O
of	O
the	O
distance	O
matrix	O
can	O
be	O
materialized	O
to	O
avoid	O
distance	O
recomputations	O
,	O
but	O
this	O
needs	O
memory	O
,	O
whereas	O
a	O
non-matrix	O
based	O
implementation	O
of	O
DBSCAN	B-Algorithm
only	O
needs	O
memory	O
.	O
</s>
<s>
DBSCAN	B-Algorithm
does	O
not	O
require	O
one	O
to	O
specify	O
the	O
number	O
of	O
clusters	O
in	O
the	O
data	O
a	O
priori	O
,	O
as	O
opposed	O
to	O
k-means	B-Algorithm
.	O
</s>
<s>
DBSCAN	B-Algorithm
can	O
find	O
arbitrarily-shaped	O
clusters	O
.	O
</s>
<s>
DBSCAN	B-Algorithm
has	O
a	O
notion	O
of	O
noise	O
,	O
and	O
is	O
robust	O
to	O
outliers	B-Algorithm
.	O
</s>
<s>
DBSCAN	B-Algorithm
requires	O
just	O
two	O
parameters	O
and	O
is	O
mostly	O
insensitive	O
to	O
the	O
ordering	O
of	O
the	O
points	O
in	O
the	O
database	O
.	O
</s>
<s>
DBSCAN	B-Algorithm
is	O
designed	O
for	O
use	O
with	O
databases	O
that	O
can	O
accelerate	O
region	O
queries	O
,	O
e.g.	O
</s>
<s>
using	O
an	O
R*	B-Data_Structure
tree	I-Data_Structure
.	O
</s>
<s>
DBSCAN	B-Algorithm
is	O
not	O
entirely	O
deterministic	O
:	O
border	O
points	O
that	O
are	O
reachable	O
from	O
more	O
than	O
one	O
cluster	O
can	O
be	O
part	O
of	O
either	O
cluster	O
,	O
depending	O
on	O
the	O
order	O
the	O
data	O
are	O
processed	O
.	O
</s>
<s>
For	O
most	O
data	O
sets	O
and	O
domains	O
,	O
this	O
situation	O
does	O
not	O
arise	O
often	O
and	O
has	O
little	O
impact	O
on	O
the	O
clustering	O
result	O
:	O
both	O
on	O
core	O
points	O
and	O
noise	O
points	O
,	O
DBSCAN	B-Algorithm
is	O
deterministic	O
.	O
</s>
<s>
DBSCAN*	O
is	O
a	O
variation	O
that	O
treats	O
border	O
points	O
as	O
noise	O
,	O
and	O
this	O
way	O
achieves	O
a	O
fully	O
deterministic	O
result	O
as	O
well	O
as	O
a	O
more	O
consistent	O
statistical	O
interpretation	O
of	O
density-connected	O
components	O
.	O
</s>
<s>
The	O
quality	O
of	O
DBSCAN	B-Algorithm
depends	O
on	O
the	O
distance	O
measure	O
used	O
in	O
the	O
function	O
regionQuery(P,ε )	O
.	O
</s>
<s>
Especially	O
for	O
high-dimensional	B-Algorithm
data	I-Algorithm
,	O
this	O
metric	O
can	O
be	O
rendered	O
almost	O
useless	O
due	O
to	O
the	O
so-called	O
"	O
Curse	O
of	O
dimensionality	O
"	O
,	O
making	O
it	O
difficult	O
to	O
find	O
an	O
appropriate	O
value	O
for	O
ε	O
.	O
</s>
<s>
DBSCAN	B-Algorithm
cannot	O
cluster	O
data	O
sets	O
well	O
with	O
large	O
differences	O
in	O
densities	O
,	O
since	O
the	O
-ε	O
combination	O
cannot	O
then	O
be	O
chosen	O
appropriately	O
for	O
all	O
clusters	O
.	O
</s>
<s>
For	O
DBSCAN	B-Algorithm
,	O
the	O
parameters	O
ε	O
and	O
are	O
needed	O
.	O
</s>
<s>
With	O
≤	O
2	O
,	O
the	O
result	O
will	O
be	O
the	O
same	O
as	O
of	O
hierarchical	B-Algorithm
clustering	I-Algorithm
with	O
the	O
single	O
link	O
metric	O
,	O
with	O
the	O
dendrogram	O
cut	O
at	O
height	O
ε	O
.	O
</s>
<s>
Alternatively	O
,	O
an	O
OPTICS	B-Algorithm
plot	O
can	O
be	O
used	O
to	O
choose	O
ε	O
,	O
but	O
then	O
the	O
OPTICS	B-Algorithm
algorithm	I-Algorithm
itself	O
can	O
be	O
used	O
to	O
cluster	O
the	O
data	O
.	O
</s>
<s>
OPTICS	B-Algorithm
can	O
be	O
seen	O
as	O
a	O
generalization	O
of	O
DBSCAN	B-Algorithm
that	O
replaces	O
the	O
ε	O
parameter	O
with	O
a	O
maximum	O
value	O
that	O
mostly	O
affects	O
performance	O
.	O
</s>
<s>
While	O
the	O
algorithm	O
is	O
much	O
easier	O
to	O
parameterize	O
than	O
DBSCAN	B-Algorithm
,	O
the	O
results	O
are	O
a	O
bit	O
more	O
difficult	O
to	O
use	O
,	O
as	O
it	O
will	O
usually	O
produce	O
a	O
hierarchical	B-Algorithm
clustering	I-Algorithm
instead	O
of	O
the	O
simple	O
data	O
partitioning	O
that	O
DBSCAN	B-Algorithm
produces	O
.	O
</s>
<s>
Recently	O
,	O
one	O
of	O
the	O
original	O
authors	O
of	O
DBSCAN	B-Algorithm
has	O
revisited	O
DBSCAN	B-Algorithm
and	O
OPTICS	B-Algorithm
,	O
and	O
published	O
a	O
refined	O
version	O
of	O
hierarchical	O
DBSCAN	B-Algorithm
(	O
HDBSCAN*	O
)	O
,	O
which	O
no	O
longer	O
has	O
the	O
notion	O
of	O
border	O
points	O
.	O
</s>
<s>
A	O
spectral	O
implementation	O
of	O
DBSCAN	B-Algorithm
is	O
related	O
to	O
spectral	B-Algorithm
clustering	I-Algorithm
in	O
the	O
trivial	O
case	O
of	O
determining	O
connected	O
graph	O
components	O
—	O
the	O
optimal	O
clusters	O
with	O
no	O
edges	O
cut	O
.	O
</s>
<s>
For	O
performance	O
reasons	O
,	O
the	O
original	O
DBSCAN	B-Algorithm
algorithm	O
remains	O
preferable	O
to	O
its	O
spectral	O
implementation	O
.	O
</s>
<s>
Generalized	O
DBSCAN	B-Algorithm
(	O
GDBSCAN	O
)	O
is	O
a	O
generalization	O
by	O
the	O
same	O
authors	O
to	O
arbitrary	O
"	O
neighborhood	O
"	O
and	O
"	O
dense	O
"	O
predicates	O
.	O
</s>
<s>
Various	O
extensions	O
to	O
the	O
DBSCAN	B-Algorithm
algorithm	O
have	O
been	O
proposed	O
,	O
including	O
methods	O
for	O
parallelization	O
,	O
parameter	O
estimation	O
,	O
and	O
support	O
for	O
uncertain	O
data	O
.	O
</s>
<s>
The	O
basic	O
idea	O
has	O
been	O
extended	O
to	O
hierarchical	B-Algorithm
clustering	I-Algorithm
by	O
the	O
OPTICS	B-Algorithm
algorithm	I-Algorithm
.	O
</s>
<s>
DBSCAN	B-Algorithm
is	O
also	O
used	O
as	O
part	O
of	O
subspace	O
clustering	B-Algorithm
algorithms	I-Algorithm
like	O
PreDeCon	O
and	O
SUBCLU	B-Algorithm
.	O
</s>
<s>
HDBSCAN	O
is	O
a	O
hierarchical	O
version	O
of	O
DBSCAN	B-Algorithm
which	O
is	O
also	O
faster	O
than	O
OPTICS	B-Algorithm
,	O
from	O
which	O
a	O
flat	O
partition	O
consisting	O
of	O
the	O
most	O
prominent	O
clusters	O
can	O
be	O
extracted	O
from	O
the	O
hierarchy	O
.	O
</s>
<s>
Apache	B-Language
Commons	I-Language
contains	O
a	O
Java	O
implementation	O
of	O
the	O
algorithm	O
running	O
in	O
quadratic	O
time	O
.	O
</s>
<s>
ELKI	B-Language
offers	O
an	O
implementation	O
of	O
DBSCAN	B-Algorithm
as	O
well	O
as	O
GDBSCAN	O
and	O
other	O
variants	O
.	O
</s>
<s>
MATLAB	B-Language
includes	O
an	O
implementation	O
of	O
DBSCAN	B-Algorithm
in	O
its	O
"	O
Statistics	O
and	O
Machine	O
Learning	O
Toolbox	O
"	O
since	O
release	O
R2019a	O
.	O
</s>
<s>
mlpack	B-Language
includes	O
an	O
implementation	O
of	O
DBSCAN	B-Algorithm
accelerated	O
with	O
dual-tree	O
range	O
search	O
techniques	O
.	O
</s>
<s>
PostGIS	B-Application
includes	O
ST_ClusterDBSCAN	O
–	O
a	O
2D	O
implementation	O
of	O
DBSCAN	B-Algorithm
that	O
uses	O
R-tree	O
index	O
.	O
</s>
<s>
R	B-Language
contains	O
implementations	O
of	O
DBSCAN	B-Algorithm
in	O
the	O
packages	O
and	O
.	O
</s>
<s>
The	O
package	O
fpc	O
does	O
not	O
have	O
index	O
support	O
(	O
and	O
thus	O
has	O
quadratic	O
runtime	O
and	O
memory	O
complexity	O
)	O
and	O
is	O
rather	O
slow	O
due	O
to	O
the	O
R	B-Language
interpreter	O
.	O
</s>
<s>
The	O
package	O
dbscan	B-Algorithm
provides	O
a	O
fast	O
C++	O
implementation	O
using	O
k-d	B-Data_Structure
trees	I-Data_Structure
(	O
for	O
Euclidean	O
distance	O
only	O
)	O
and	O
also	O
includes	O
implementations	O
of	O
DBSCAN*	O
,	O
HDBSCAN*	O
,	O
OPTICS	B-Algorithm
,	O
OPTICSXi	O
,	O
and	O
other	O
related	O
methods	O
.	O
</s>
<s>
scikit-learn	B-Application
includes	O
a	O
Python	O
implementation	O
of	O
DBSCAN	B-Algorithm
for	O
arbitrary	O
Minkowski	O
metrics	O
,	O
which	O
can	O
be	O
accelerated	O
using	O
k-d	B-Data_Structure
trees	I-Data_Structure
and	O
ball	B-Data_Structure
trees	I-Data_Structure
but	O
which	O
uses	O
worst-case	O
quadratic	O
memory	O
.	O
</s>
<s>
library	O
includes	O
a	O
Python	O
and	O
C++	O
implementation	O
of	O
DBSCAN	B-Algorithm
for	O
Euclidean	O
distance	O
only	O
as	O
well	O
as	O
OPTICS	B-Algorithm
algorithm	I-Algorithm
.	O
</s>
<s>
includes	O
an	O
implementation	O
of	O
the	O
DBSCAN	B-Algorithm
algorithm	O
with	O
k-d	B-Data_Structure
tree	I-Data_Structure
support	O
for	O
Euclidean	O
distance	O
only	O
.	O
</s>
<s>
Weka	B-Language
contains	O
(	O
as	O
an	O
optional	O
package	O
in	O
latest	O
versions	O
)	O
a	O
basic	O
implementation	O
of	O
DBSCAN	B-Algorithm
that	O
runs	O
in	O
quadratic	O
time	O
and	O
linear	O
memory	O
.	O
</s>
