diff --git a/data_hacking/hcluster/hcluster.py b/data_hacking/hcluster/hcluster.py index 899a7f7..cc5e9aa 100644 --- a/data_hacking/hcluster/hcluster.py +++ b/data_hacking/hcluster/hcluster.py @@ -285,7 +285,8 @@ def find_root(self, G, node): root = G.predecessors(root)[0] return root - def find_parent(self, G, node): + def find_parent(self, G, node, root=True): + if root: return self.find_root(G, node) # Temp hack for testing return G.predecessors(node)[0] def common_features(self, G, root):