Skip to main content


Table 1 The pseudocode of the motif extraction algorithm.

From: Mining, compressing and classifying with extensible motifs

Main() Iterate(m, B, Result)
{ {
Result ← {}; G:l     m'm;
B ← {m i |m i is a cell}; G:2     For each b = Extract(B) with
For each m = Extract(B) G:3        ((b ~-compatible m'
Iterate(m, B, Result);           OR (m' ~-compatible b))
ResultResult; G:4              If (m' ~-compatible b)
} G:5                 m t m' ~ b;
  G:6                 If Nodelnconsistent(m t ) exit;
  G:7                 If (| m' | = | b |) BB - {b};
  G:8                 If (|| ≤ K)
  G:9                    m'm t ;
  G:10                    Iterate(m', B, Result);
  G:11              If (b ~-compatible m')
  G:12                 m t b ~ m';
  G:13                 If Nodelnconsistent(m t ) exit;
  G:14                 If (| m' | = | b |) BB - {b};
  G:15                 If (|| ≥ K)
  G:16                    m'm t ;
  G:17                    Iterate(m', B, Result);
  G:18              For each r Result with r = m'
  G:19                 If (m' is not maximal w.r.t. r) return;
  G:20              ResultResult {m'};