Added code to perform tree aggregation based on a tree similarity algorithm