Index: branches/HeuristicLab.EvolutionTracking/HeuristicLab.Problems.DataAnalysis.Symbolic/3.4/TreeMatching/SymbolicExpressionTreeBottomUpSimilarityCalculator.cs
===================================================================
--- branches/HeuristicLab.EvolutionTracking/HeuristicLab.Problems.DataAnalysis.Symbolic/3.4/TreeMatching/SymbolicExpressionTreeBottomUpSimilarityCalculator.cs	(revision 12287)
+++ branches/HeuristicLab.EvolutionTracking/HeuristicLab.Problems.DataAnalysis.Symbolic/3.4/TreeMatching/SymbolicExpressionTreeBottomUpSimilarityCalculator.cs	(revision 12891)
@@ -1,3 +1,4 @@
 ﻿#region License Information
+
 /* HeuristicLab
  * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL)
@@ -18,5 +19,6 @@
  * along with HeuristicLab. If not, see <http://www.gnu.org/licenses/>.
  */
-#endregion
+
+#endregion License Information
 
 using System;
@@ -32,4 +34,5 @@
 
 namespace HeuristicLab.Problems.DataAnalysis.Symbolic {
+
   [StorableClass]
   [Item("SymbolicExpressionTreeBottomUpSimilarityCalculator", "A similarity calculator which uses the tree bottom-up distance as a similarity metric.")]
@@ -37,5 +40,7 @@
     private readonly HashSet<string> commutativeSymbols = new HashSet<string> { "Addition", "Multiplication", "Average", "And", "Or", "Xor" };
 
-    public SymbolicExpressionTreeBottomUpSimilarityCalculator() { }
+    public SymbolicExpressionTreeBottomUpSimilarityCalculator() {
+    }
+
     protected override bool IsCommutative { get { return true; } }
 
@@ -107,5 +112,5 @@
 
         // at this point we know that v and w are isomorphic, however, the mapping cannot be done directly
-        // (as in the paper) because the trees are unordered (subtree order might differ). the solution is 
+        // (as in the paper) because the trees are unordered (subtree order might differ). the solution is
         // to sort subtrees from under commutative labels (this will work because the subtrees are isomorphic!)
         // while iterating over the two subtrees
Index: branches/HeuristicLab.EvolutionTracking/HeuristicLab.Problems.DataAnalysis.Symbolic/3.4/TreeMatching/SymbolicExpressionTreeNodeComparer.cs
===================================================================
--- branches/HeuristicLab.EvolutionTracking/HeuristicLab.Problems.DataAnalysis.Symbolic/3.4/TreeMatching/SymbolicExpressionTreeNodeComparer.cs	(revision 12287)
+++ branches/HeuristicLab.EvolutionTracking/HeuristicLab.Problems.DataAnalysis.Symbolic/3.4/TreeMatching/SymbolicExpressionTreeNodeComparer.cs	(revision 12891)
@@ -18,5 +18,5 @@
  * along with HeuristicLab. If not, see <http://www.gnu.org/licenses/>.
  */
-#endregion
+#endregion License Information
 
 using System;
@@ -29,4 +29,5 @@
   // - used for bringing subtrees to a "canonical" form when the operation allows reordering of arguments
   public class SymbolicExpressionTreeNodeComparer : ISymbolicExpressionTreeNodeComparer {
+
     public static int CompareNodes(ISymbolicExpressionTreeNode a, ISymbolicExpressionTreeNode b) {
       var ta = a as SymbolicExpressionTreeTerminalNode;
@@ -69,4 +70,3 @@
     }
   }
-
 }
Index: branches/HeuristicLab.EvolutionTracking/HeuristicLab.Problems.DataAnalysis.Symbolic/3.4/TreeMatching/SymbolicExpressionTreePhenotypicSimilarityCalculator.cs
===================================================================
--- branches/HeuristicLab.EvolutionTracking/HeuristicLab.Problems.DataAnalysis.Symbolic/3.4/TreeMatching/SymbolicExpressionTreePhenotypicSimilarityCalculator.cs	(revision 12287)
+++ branches/HeuristicLab.EvolutionTracking/HeuristicLab.Problems.DataAnalysis.Symbolic/3.4/TreeMatching/SymbolicExpressionTreePhenotypicSimilarityCalculator.cs	(revision 12891)
@@ -65,10 +65,12 @@
 
       OnlineCalculatorError error;
-      var r2 = OnlinePearsonsRSquaredCalculator.Calculate(v1, v2, out error);
+      var r = OnlinePearsonsRCalculator.Calculate(v1, v2, out error);
+
+      var r2 = error == OnlineCalculatorError.None ? r * r : 0;
 
       if (r2 > 1.0)
         r2 = 1.0;
 
-      return error == OnlineCalculatorError.None ? r2 : 0;
+      return r2;
     }
 
@@ -87,10 +89,12 @@
 
       OnlineCalculatorError error;
-      var r2 = OnlinePearsonsRSquaredCalculator.Calculate(leftValues, rightValues, out error);
+      var r = OnlinePearsonsRCalculator.Calculate(leftValues, rightValues, out error);
+
+      var r2 = error == OnlineCalculatorError.None ? r * r : 0;
 
       if (r2 > 1.0)
-        r2 = 1.0; // sometimes due to fp errors it can happen that the r2 is over 1 (like 1.0000000009)
+        r2 = 1.0;
 
-      return error == OnlineCalculatorError.None ? r2 : 0;
+      return r2;
     }
   }
