Skip to main content
. 2016 Jan 4;16(1):53. doi: 10.3390/s16010053
Algorithm 1. DBSCAN procedure
Input: a set of objects S
Output: a cluster of objects C
Set all the objects in S to be unprocessed, CØ;
while there is an unprocessed object in S
  Choose an arbitrary unprocessed object pS and calculate Nε(p);
  if|Nε(p)|MinPts
   Build a new cluster E containing the only object p and add E into C;
   ChildNε(p)p;
   while there exist unprocessed or noise objects in Child
    for each unprocessed or noise object qChild
     Insert q into E and compute Nε(q);
     if |Nε(q)|MinPts
      ChildChildNε(q)q;
     end if
    end for
   end while
  else
    Set the object p to be noise;
  end if
end while