Index: /trunk/sources/HeuristicLab.Problems.DataAnalysis.Views/3.4/Regression/RegressionSolutionVariableImpactsView.Designer.cs
===================================================================
--- /trunk/sources/HeuristicLab.Problems.DataAnalysis.Views/3.4/Regression/RegressionSolutionVariableImpactsView.Designer.cs	(revision 15672)
+++ /trunk/sources/HeuristicLab.Problems.DataAnalysis.Views/3.4/Regression/RegressionSolutionVariableImpactsView.Designer.cs	(revision 15673)
@@ -19,6 +19,4 @@
  */
 #endregion
-using System;
-using System.Linq;
 
 namespace HeuristicLab.Problems.DataAnalysis.Views {
Index: /trunk/sources/HeuristicLab.Problems.DataAnalysis.Views/3.4/Regression/RegressionSolutionVariableImpactsView.cs
===================================================================
--- /trunk/sources/HeuristicLab.Problems.DataAnalysis.Views/3.4/Regression/RegressionSolutionVariableImpactsView.cs	(revision 15672)
+++ /trunk/sources/HeuristicLab.Problems.DataAnalysis.Views/3.4/Regression/RegressionSolutionVariableImpactsView.cs	(revision 15673)
@@ -32,4 +32,10 @@
   [Content(typeof(IRegressionSolution))]
   public partial class RegressionSolutionVariableImpactsView : DataAnalysisSolutionEvaluationView {
+    private enum SortingCriteria {
+      ImpactValue,
+      Occurrence,
+      VariableName
+    }
+
     private Dictionary<string, double> rawVariableImpacts = new Dictionary<string, double>();
 
@@ -46,6 +52,6 @@
 
       //Little workaround. If you fill the ComboBox-Items in the other partial class, the UI-Designer will moan.
-      this.sortByComboBox.Items.AddRange(Enum.GetValues(typeof(RegressionSolutionVariableImpactsCalculator.SortingCriteria)).Cast<object>().ToArray());
-      this.sortByComboBox.SelectedItem = RegressionSolutionVariableImpactsCalculator.SortingCriteria.ImpactValue;
+      this.sortByComboBox.Items.AddRange(Enum.GetValues(typeof(SortingCriteria)).Cast<object>().ToArray());
+      this.sortByComboBox.SelectedItem = SortingCriteria.ImpactValue;
 
       this.dataPartitionComboBox.SelectedIndex = 0;
@@ -96,16 +102,16 @@
       //Update the default ordering (asc,desc), but remove the eventHandler beforehand (otherwise the data would be ordered twice)
       ascendingCheckBox.CheckedChanged -= ascendingCheckBox_CheckedChanged;
-      switch ((RegressionSolutionVariableImpactsCalculator.SortingCriteria)sortByComboBox.SelectedItem) {
-        case RegressionSolutionVariableImpactsCalculator.SortingCriteria.ImpactValue:
+      switch ((SortingCriteria)sortByComboBox.SelectedItem) {
+        case SortingCriteria.ImpactValue:
           ascendingCheckBox.Checked = false;
           break;
-        case RegressionSolutionVariableImpactsCalculator.SortingCriteria.Occurrence:
+        case SortingCriteria.Occurrence:
           ascendingCheckBox.Checked = true;
           break;
-        case RegressionSolutionVariableImpactsCalculator.SortingCriteria.VariableName:
+        case SortingCriteria.VariableName:
           ascendingCheckBox.Checked = true;
           break;
         default:
-          throw new Exception("Cannot interpret SortingCriteria");
+          throw new NotImplementedException("Ordering for selected SortingCriteria not implemented");
       }
       ascendingCheckBox.CheckedChanged += ascendingCheckBox_CheckedChanged;
@@ -121,17 +127,15 @@
     #region Helper Methods         
     private void UpdateVariableImpacts() {
-      if (Content == null || replacementComboBox.SelectedIndex < 0
-        || factorVarReplComboBox.SelectedIndex < 0
-        || dataPartitionComboBox.SelectedIndex < 0) return;
+      if (Content == null) { return; }
+      if (replacementComboBox.SelectedIndex < 0) { return; }
+      if (dataPartitionComboBox.SelectedIndex < 0) { return; }
+      if (factorVarReplComboBox.SelectedIndex < 0) { return; }
+
+      variableImactsArrayView.Caption = Content.Name + " Variable Impacts";
+
       var mainForm = (MainForm.WindowsForms.MainForm)MainFormManager.MainForm;
-      variableImactsArrayView.Caption = Content.Name + " Variable Impacts";
-      var replMethod =
-         (RegressionSolutionVariableImpactsCalculator.ReplacementMethodEnum)
-           replacementComboBox.Items[replacementComboBox.SelectedIndex];
-      var factorReplMethod =
-        (RegressionSolutionVariableImpactsCalculator.FactorReplacementMethodEnum)
-          factorVarReplComboBox.Items[factorVarReplComboBox.SelectedIndex];
-      var dataPartition =
-        (RegressionSolutionVariableImpactsCalculator.DataPartitionEnum)dataPartitionComboBox.SelectedItem;
+      var replMethod = (RegressionSolutionVariableImpactsCalculator.ReplacementMethodEnum)replacementComboBox.Items[replacementComboBox.SelectedIndex];
+      var factorReplMethod = (RegressionSolutionVariableImpactsCalculator.FactorReplacementMethodEnum)factorVarReplComboBox.Items[factorVarReplComboBox.SelectedIndex];
+      var dataPartition = (RegressionSolutionVariableImpactsCalculator.DataPartitionEnum)dataPartitionComboBox.SelectedItem;
 
       Task.Factory.StartNew(() => {
@@ -146,7 +150,7 @@
           rawVariableImpacts.Clear();
           originalVariableOrdering.ForEach(v => rawVariableImpacts.Add(v, impacts.First(vv => vv.Item1 == v).Item2));
+          UpdateDataOrdering();
         } finally {
           mainForm.RemoveOperationProgressFromView(this);
-          UpdateDataOrdering();
         }
       });
@@ -159,7 +163,9 @@
     private void UpdateDataOrdering() {
       //Check if valid sortingCriteria is selected and data exists
-      if (sortByComboBox.SelectedIndex == -1 || rawVariableImpacts == null || !rawVariableImpacts.Any()) { return; }
+      if (sortByComboBox.SelectedIndex == -1) { return; }
+      if (rawVariableImpacts == null) { return; }
+      if (!rawVariableImpacts.Any()) { return; }
 
-      var selectedItem = (RegressionSolutionVariableImpactsCalculator.SortingCriteria)sortByComboBox.SelectedItem;
+      var selectedItem = (SortingCriteria)sortByComboBox.SelectedItem;
       bool ascending = ascendingCheckBox.Checked;
 
@@ -168,16 +174,18 @@
       //Sort accordingly
       switch (selectedItem) {
-        case RegressionSolutionVariableImpactsCalculator.SortingCriteria.ImpactValue:
-          orderedEntries = ascending ? rawVariableImpacts.OrderBy(v => v.Value) : rawVariableImpacts.OrderByDescending(v => v.Value);
+        case SortingCriteria.ImpactValue:
+          orderedEntries = rawVariableImpacts.OrderBy(v => v.Value);
           break;
-        case RegressionSolutionVariableImpactsCalculator.SortingCriteria.Occurrence:
-          orderedEntries = ascending ? rawVariableImpacts : rawVariableImpacts.Reverse();
+        case SortingCriteria.Occurrence:
+          orderedEntries = rawVariableImpacts;
           break;
-        case RegressionSolutionVariableImpactsCalculator.SortingCriteria.VariableName:
-          orderedEntries = ascending ? rawVariableImpacts.OrderBy(v => v.Key, new NaturalStringComparer()) : rawVariableImpacts.OrderByDescending(v => v.Key, new NaturalStringComparer());
+        case SortingCriteria.VariableName:
+          orderedEntries = rawVariableImpacts.OrderBy(v => v.Key, new NaturalStringComparer());
           break;
         default:
-          throw new Exception("Cannot interpret SortingCriteria");
+          throw new NotImplementedException("Ordering for selected SortingCriteria not implemented");
       }
+
+      if (!ascending) { orderedEntries = orderedEntries.Reverse(); }
 
       //Write the data back
Index: /trunk/sources/HeuristicLab.Problems.DataAnalysis/3.4/Implementation/Regression/RegressionSolutionVariableImpactsCalculator.cs
===================================================================
--- /trunk/sources/HeuristicLab.Problems.DataAnalysis/3.4/Implementation/Regression/RegressionSolutionVariableImpactsCalculator.cs	(revision 15672)
+++ /trunk/sources/HeuristicLab.Problems.DataAnalysis/3.4/Implementation/Regression/RegressionSolutionVariableImpactsCalculator.cs	(revision 15673)
@@ -52,10 +52,5 @@
       All
     }
-    public enum SortingCriteria {
-      ImpactValue,
-      Occurrence,
-      VariableName
-    }
-
+   
     private const string ReplacementParameterName = "Replacement Method";
     private const string DataPartitionParameterName = "DataPartition";
