Index: /branches/DataPreprocessing/HeuristicLab 3.3.sln
===================================================================
--- /branches/DataPreprocessing/HeuristicLab 3.3.sln	(revision 10978)
+++ /branches/DataPreprocessing/HeuristicLab 3.3.sln	(revision 10979)
@@ -1,5 +1,7 @@
 ﻿
 Microsoft Visual Studio Solution File, Format Version 12.00
-# Visual Studio 2012
+# Visual Studio 2013
+VisualStudioVersion = 12.0.30501.0
+MinimumVisualStudioVersion = 10.0.40219.1
 Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution Items", "{96396439-A764-4022-A8D2-BE021449B8D1}"
 	ProjectSection(SolutionItems) = preProject
@@ -1924,6 +1926,3 @@
 		HideSolutionNode = FALSE
 	EndGlobalSection
-	GlobalSection(Performance) = preSolution
-		HasPerformanceSessions = true
-	EndGlobalSection
 EndGlobal
Index: /branches/DataPreprocessing/HeuristicLab.DataPreprocessing.Views/3.4/DataCompletenessView.Designer.cs
===================================================================
--- /branches/DataPreprocessing/HeuristicLab.DataPreprocessing.Views/3.4/DataCompletenessView.Designer.cs	(revision 10978)
+++ /branches/DataPreprocessing/HeuristicLab.DataPreprocessing.Views/3.4/DataCompletenessView.Designer.cs	(revision 10979)
@@ -28,5 +28,4 @@
       System.Windows.Forms.DataVisualization.Charting.ChartArea chartArea1 = new System.Windows.Forms.DataVisualization.Charting.ChartArea();
       System.Windows.Forms.DataVisualization.Charting.Legend legend1 = new System.Windows.Forms.DataVisualization.Charting.Legend();
-      System.Windows.Forms.DataVisualization.Charting.Series series1 = new System.Windows.Forms.DataVisualization.Charting.Series();
       this.chart = new HeuristicLab.Visualization.ChartControlsExtensions.EnhancedChart();
       ((System.ComponentModel.ISupportInitialize)(this.chart)).BeginInit();
@@ -35,4 +34,7 @@
       // chart
       // 
+      this.chart.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) 
+            | System.Windows.Forms.AnchorStyles.Left) 
+            | System.Windows.Forms.AnchorStyles.Right)));
       chartArea1.Name = "ChartArea1";
       this.chart.ChartAreas.Add(chartArea1);
@@ -41,8 +43,4 @@
       this.chart.Location = new System.Drawing.Point(4, 4);
       this.chart.Name = "chart";
-      series1.ChartArea = "ChartArea1";
-      series1.Legend = "Legend1";
-      series1.Name = "Series1";
-      this.chart.Series.Add(series1);
       this.chart.Size = new System.Drawing.Size(486, 337);
       this.chart.TabIndex = 0;
Index: /branches/DataPreprocessing/HeuristicLab.DataPreprocessing.Views/3.4/DataCompletenessView.cs
===================================================================
--- /branches/DataPreprocessing/HeuristicLab.DataPreprocessing.Views/3.4/DataCompletenessView.cs	(revision 10978)
+++ /branches/DataPreprocessing/HeuristicLab.DataPreprocessing.Views/3.4/DataCompletenessView.cs	(revision 10979)
@@ -7,4 +7,5 @@
 using HeuristicLab.DataPreprocessing.Implementations;
 using System.Drawing;
+using System.Windows.Forms.DataVisualization.Charting;
 
 namespace HeuristicLab.DataPreprocessing.Views {
@@ -15,11 +16,9 @@
   {
 
-    protected DataRowVisualProperties.DataRowChartType chartType;
-    protected string chartTitle;
-
-    private const string DEFAULT_CHART_TITLE = "DataCompletenessChart";
-
     //list of columns, bool indicates wether the cell is a missing value or not
     private List<List<bool>> matrix = new List<List<bool>>();
+    //series colors
+    private static Color colorNonMissingVal = Color.CornflowerBlue;
+    private static Color colorMissingVal = Color.Orange;
 
     public new DataCompletenessChartContent Content
@@ -33,6 +32,4 @@
     {
       InitializeComponent();
-      chartType = DataRowVisualProperties.DataRowChartType.Bars;
-      chartTitle = DEFAULT_CHART_TITLE;
     }
 
@@ -42,7 +39,23 @@
       if (Content != null)
       {
+        //chart.PrePaint += chart_PrePaint;
+        //chart.CustomizeLegend += chart_CustomizeLegend;
         InitData();
       }
     }
+
+    
+    /*
+    void chart_CustomizeLegend(object sender, CustomizeLegendEventArgs e)
+    {
+      foreach (LegendItem li in e.LegendItems)
+      {
+        int label;
+        int.TryParse(li.Cells[0].ToString(), out label);
+
+        li.Cells[0].Text = "Banane";
+        //li.Cells[0].Text = (label - Content.DataGridLogic.Rows).ToString();
+      }
+    }*/
 
     private void InitData()
@@ -59,20 +72,52 @@
       }
       List<List<int>> yValuesPerColumn = ProcessMatrixForCharting(matrix, missingValueIndices);
-      createSeries(yValuesPerColumn);
-      //CreateChart();
+      PrepareChart();
+      CreateSeries(yValuesPerColumn);
     }
 
-    private void createSeries(List<List<int>> yValuesPerColumn)
+    private void PrepareChart()
+    {
+      chart.Titles.Add("DataCompletenessChart");
+      chart.ChartAreas[0].AxisX.MajorGrid.LineWidth = 0;
+      chart.ChartAreas[0].AxisY.MajorGrid.LineWidth = 0;
+      chart.ChartAreas[0].AxisX.IsMarginVisible = false;
+      chart.ChartAreas[0].AxisY.IsMarginVisible = false;
+      //custom x axis label
+      double from = 0.5;
+      foreach (String columnName in Content.DataGridLogic.ColumnNames)
+      {
+        double to = from + 1;
+        chart.ChartAreas[0].AxisX.CustomLabels.Add(from, to, columnName);
+        from = to;
+      }
+      //custom y axis label
+      chart.ChartAreas[0].AxisY.IsReversed = true;
+    }
+
+
+
+    private void CreateSeries(List<List<int>> yValuesPerColumn)
     {
       //prepare series
-      int seriesCount = determineSeriesCount(yValuesPerColumn);
+      int seriesCount = DetermineSeriesCount(yValuesPerColumn);
       for (int i = 0; i < seriesCount; i++)
       {
-        chart.Series.Add("series"+i);
-        chart.Series["series"+i].ChartType = System.Windows.Forms.DataVisualization.Charting.SeriesChartType.StackedColumn;
+        chart.Series.Add(CreateSeriesName(i));
+        Series series = chart.Series[CreateSeriesName(i)];
+        series.ChartType = System.Windows.Forms.DataVisualization.Charting.SeriesChartType.StackedColumn;
+        series.IsVisibleInLegend = false;
+        series["PointWidth"] = "1.0";
         if (i % 2 == 0)
-          chart.Series["series" + i].Color = Color.Blue;
+        {
+          if (i == 0) //show legend for non missing values only once
+            series.IsVisibleInLegend = true;
+          series.Color = colorNonMissingVal;
+        }
         else
-          chart.Series["series" + i].Color = Color.White;
+        {
+          if (i == 1) //show legend for missing values only once
+            series.IsVisibleInLegend = true;
+          series.Color = colorMissingVal;
+        }
       }
       //fill series
@@ -82,7 +127,7 @@
         for (int j = 0; j < seriesCount; j++) {
           if (column.Count - 1 < j) {
-            chart.Series["series"+j].Points.AddY(0);
+            chart.Series[CreateSeriesName(j)].Points.AddY(0);
           } else {
-            chart.Series["series" + j].Points.AddY(column[j]);
+            chart.Series[CreateSeriesName(j)].Points.AddY(column[j]);
           }
         }
@@ -90,5 +135,15 @@
     }
 
-    private int determineSeriesCount(List<List<int>> yValuesPerColumn)
+    private String CreateSeriesName(int index)
+    {
+      if (index == 0)
+        return "non-missing value";
+      else if (index == 1)
+        return "missing value";
+      return "series" + index;
+    }
+
+    #region data_preparation_for_chartseries
+    private int DetermineSeriesCount(List<List<int>> yValuesPerColumn)
     {
       int highest = 0;
@@ -121,47 +176,14 @@
         }
         yValues.Add(valueCount);
-            /*
-        List<int> yValues = new List<int>();
-        bool missingChanged = true;
-        while ()
-             * */
+        if (missingState) //handle last missing
+        {
+          yValues.Add(0);
+        }
+        //yValues.Reverse();
         columnsYValues.Add(yValues);
       }
       return columnsYValues;
     }
-
-    const String missingValue = "Red";
-    const String existingValue = "DarkBlue";
-
-
-    private void CreateChart()
-    {
-      object[] temp = new[] { "1", "50" };
-      object[] temp2 = new[] { "50", "1000" };
-      chart.Series.Add(missingValue);
-      chart.Series.Add(existingValue);
-
-      for(int i=0; i < matrix.Count; i++) {
-        List<bool> column = matrix[i];
-        for (int j = 0; j < column.Count; j++ )
-        {
-          chart.Series[missingValue].Points.AddXY(i, temp);
-          chart.Series[existingValue].Points.AddXY(i, temp2);
-          chart.Series[missingValue].ChartType = System.Windows.Forms.DataVisualization.Charting.SeriesChartType.StackedBar;
-          chart.Series[existingValue].ChartType = System.Windows.Forms.DataVisualization.Charting.SeriesChartType.StackedBar;
-        }
-      }
-    }
-
-    /*
-    private DataRow columnToDataRow(List<bool> column, int i)
-    {
-      DataRow row = new DataRow("row"+i);
-      foreach (bool missing in column) {
-        row.Values.Add(missing? 1 : 0);
-      }
-      return row;
-    }*/
-
+    #endregion
   }
 }
Index: /branches/DataPreprocessing/HeuristicLab.DataPreprocessing.Views/3.4/FilterView.Designer.cs
===================================================================
--- /branches/DataPreprocessing/HeuristicLab.DataPreprocessing.Views/3.4/FilterView.Designer.cs	(revision 10978)
+++ /branches/DataPreprocessing/HeuristicLab.DataPreprocessing.Views/3.4/FilterView.Designer.cs	(revision 10979)
@@ -42,8 +42,8 @@
       this.rBtnAnd = new System.Windows.Forms.RadioButton();
       this.groupBox1 = new System.Windows.Forms.GroupBox();
+      this.label4 = new System.Windows.Forms.Label();
       this.label1 = new System.Windows.Forms.Label();
       this.label2 = new System.Windows.Forms.Label();
       this.label3 = new System.Windows.Forms.Label();
-      this.label4 = new System.Windows.Forms.Label();
       this.groupBoxFilter.SuspendLayout();
       this.groupBoxFilterInfo.SuspendLayout();
@@ -152,4 +152,5 @@
       // 
       this.applyFilterButton.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
+      this.applyFilterButton.Cursor = System.Windows.Forms.Cursors.Default;
       this.applyFilterButton.Enabled = false;
       this.applyFilterButton.Location = new System.Drawing.Point(554, 628);
@@ -165,4 +166,5 @@
       this.rBtnOr.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)));
       this.rBtnOr.AutoSize = true;
+      this.rBtnOr.Cursor = System.Windows.Forms.Cursors.Default;
       this.rBtnOr.Enabled = false;
       this.rBtnOr.Location = new System.Drawing.Point(60, 634);
@@ -178,4 +180,5 @@
       this.rBtnAnd.AutoSize = true;
       this.rBtnAnd.Checked = true;
+      this.rBtnAnd.Cursor = System.Windows.Forms.Cursors.Default;
       this.rBtnAnd.Enabled = false;
       this.rBtnAnd.Location = new System.Drawing.Point(10, 634);
@@ -203,4 +206,14 @@
       this.groupBox1.Text = "Filter Info";
       // 
+      // label4
+      // 
+      this.label4.AutoSize = true;
+      this.label4.Location = new System.Drawing.Point(15, 98);
+      this.label4.Name = "label4";
+      this.label4.Size = new System.Drawing.Size(455, 13);
+      this.label4.TabIndex = 12;
+      this.label4.Text = "The Apply Filter Button permanently activates the filters. This means unfiltered " +
+    "rows are deleted.";
+      // 
       // label1
       // 
@@ -231,14 +244,4 @@
       this.label3.TabIndex = 6;
       this.label3.Text = "A filter specifies the data rows which should remain.";
-      // 
-      // label4
-      // 
-      this.label4.AutoSize = true;
-      this.label4.Location = new System.Drawing.Point(15, 98);
-      this.label4.Name = "label4";
-      this.label4.Size = new System.Drawing.Size(455, 13);
-      this.label4.TabIndex = 12;
-      this.label4.Text = "The Apply Filter Button permanently activates the filters. This means unfiltered " +
-    "rows are deleted.";
       // 
       // FilterView
Index: /branches/DataPreprocessing/HeuristicLab.DataPreprocessing.Views/3.4/FilterView.cs
===================================================================
--- /branches/DataPreprocessing/HeuristicLab.DataPreprocessing.Views/3.4/FilterView.cs	(revision 10978)
+++ /branches/DataPreprocessing/HeuristicLab.DataPreprocessing.Views/3.4/FilterView.cs	(revision 10979)
@@ -72,6 +72,6 @@
 
         tbFiltered.Text = filteredCnt.ToString();
-        double percentage = result.Length == 0 ? 0.0 : filteredCnt * 100 / result.Length;
-        tbPercentage.Text = percentage.ToString() + "%";
+        double percentage = result.Length == 0 ? 0.0 : filteredCnt * 100 / (double)result.Length;
+        tbPercentage.Text = String.Format("{0:0.0000}%", percentage);
         tbTotal.Text = result.Length.ToString();
     }
