Skip to main content
. 2022 Nov 17;24(11):1678. doi: 10.3390/e24111678
Algorithm 3 Birch
    Input
          X     input vectors, {x1,x2,,xn}
          T     Threshold value for CF Tree
    Output
          C     set of clusters
    procedure BIRCH
          for each xiX do
                find the leaf node for insertion
                if leaf node is within the threshold condition then
                      add xi to cluster
                      update CF triples
                else
                      if there is space for insertion then
                            insert xi as a single cluster
                            update CF triples
                      else
                            split leaf node
                            redistribute CF features
                      end if
                end if
          end for
    end procedure