Index: /branches/2913_MatlabScriptProblemInstanceProvider/HeuristicLab.Problems.Instances.DataAnalysis.Views/3.3/HeuristicLab.Problems.Instances.DataAnalysis.Views-3.3.csproj
===================================================================
--- /branches/2913_MatlabScriptProblemInstanceProvider/HeuristicLab.Problems.Instances.DataAnalysis.Views/3.3/HeuristicLab.Problems.Instances.DataAnalysis.Views-3.3.csproj	(revision 15925)
+++ /branches/2913_MatlabScriptProblemInstanceProvider/HeuristicLab.Problems.Instances.DataAnalysis.Views/3.3/HeuristicLab.Problems.Instances.DataAnalysis.Views-3.3.csproj	(revision 15926)
@@ -123,4 +123,16 @@
       <DependentUpon>RegressionImportDialog.cs</DependentUpon>
     </Compile>
+    <Compile Include="Regression\Matlab\IMLVariablesLoader.cs">
+      <SubType>Form</SubType>
+    </Compile>
+    <Compile Include="Regression\Matlab\MLDoubleArrayLoader.cs">
+      <SubType>Form</SubType>
+    </Compile>
+    <Compile Include="Regression\Matlab\MLTimeseriesLoader.cs">
+      <SubType>Form</SubType>
+    </Compile>
+    <Compile Include="Regression\Matlab\MLVariablesLoader.cs">
+      <SubType>Form</SubType>
+    </Compile>
     <Compile Include="Regression\Matlab\RegressionMatlabImportDialog.cs">
       <SubType>Form</SubType>
Index: /branches/2913_MatlabScriptProblemInstanceProvider/HeuristicLab.Problems.Instances.DataAnalysis.Views/3.3/Regression/Matlab/IMLVariablesLoader.cs
===================================================================
--- /branches/2913_MatlabScriptProblemInstanceProvider/HeuristicLab.Problems.Instances.DataAnalysis.Views/3.3/Regression/Matlab/IMLVariablesLoader.cs	(revision 15926)
+++ /branches/2913_MatlabScriptProblemInstanceProvider/HeuristicLab.Problems.Instances.DataAnalysis.Views/3.3/Regression/Matlab/IMLVariablesLoader.cs	(revision 15926)
@@ -0,0 +1,42 @@
+﻿using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+using System.Threading;
+using System.Threading.Tasks;
+using System.Windows.Forms;
+using HeuristicLab.Collections;
+using HeuristicLab.Common;
+using HeuristicLab.Problems.DataAnalysis;
+using HeuristicLab.Problems.Instances.DataAnalysis.Regression.Matlab.Api;
+using HeuristicLab.Problems.Instances.DataAnalysis.Regression.Matlab.Api.Types;
+
+namespace HeuristicLab.Problems.Instances.DataAnalysis.Views.Regression.Matlab {
+  public partial class RegressionMatlabImportDialog {
+    private interface IMLVariablesLoader {
+
+      /// <summary>
+      /// This event will be fired after the number of variables was changed.
+      /// </summary>
+      event EventHandler<EventArgs<int>> NumberOfSelectedVariablesChanged;
+
+      /// <summary>
+      /// This property contains the selected variables.
+      /// </summary>
+      IEnumerable<MLVariableInfo> SelectedVariables { get; }
+          
+      /// <summary>
+      /// Returns a dataset which contains the data of the selected Matlab variables.
+      /// </summary>
+      /// <param name="mlConnector"></param>
+      /// <returns></returns>
+      Dataset GetPreviewDataset(IMatlabConnector mlConnector, CancellationToken token);
+
+      /// <summary>
+      /// Shows the given Variables at the list view.
+      /// </summary>
+      /// <param name="variables"></param>
+      void DisplayVariables(IEnumerable<MLVariableInfo> variables);
+    }
+  }  
+}
Index: /branches/2913_MatlabScriptProblemInstanceProvider/HeuristicLab.Problems.Instances.DataAnalysis.Views/3.3/Regression/Matlab/MLDoubleArrayLoader.cs
===================================================================
--- /branches/2913_MatlabScriptProblemInstanceProvider/HeuristicLab.Problems.Instances.DataAnalysis.Views/3.3/Regression/Matlab/MLDoubleArrayLoader.cs	(revision 15926)
+++ /branches/2913_MatlabScriptProblemInstanceProvider/HeuristicLab.Problems.Instances.DataAnalysis.Views/3.3/Regression/Matlab/MLDoubleArrayLoader.cs	(revision 15926)
@@ -0,0 +1,39 @@
+﻿using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+using System.Threading;
+using System.Threading.Tasks;
+using System.Windows.Forms;
+using HeuristicLab.Problems.DataAnalysis;
+using HeuristicLab.Problems.Instances.DataAnalysis.Regression.Matlab.Api;
+using HeuristicLab.Problems.Instances.DataAnalysis.Regression.Matlab.Api.Types;
+
+namespace HeuristicLab.Problems.Instances.DataAnalysis.Views.Regression.Matlab {
+  public partial class RegressionMatlabImportDialog {
+    private class MLDoubleArrayLoader : MLVariablesLoader {
+      public MLDoubleArrayLoader(RegressionMatlabImportDialog importDialog, CheckedListBox variablesListBox) 
+        : base(importDialog, variablesListBox, MLDatatype.DoubleArray) {
+      }
+      
+      public override Dataset GetPreviewDataset(IMatlabConnector mlConnector, CancellationToken token) {
+        var doubleArrays = new List<MLDoubleArray>();        
+
+        foreach (MLVariableInfo item in _variablesListBox.CheckedItems.Cast< MLVariableInfo>().ToList()) {
+          if (token.IsCancellationRequested) {
+            return null;
+          }
+
+          if (item.Datatype == _mlDatatype) {
+            var val = mlConnector.GetDoubleArray(item.VarName);
+            if (val != null) {
+              doubleArrays.Add(val);
+            }
+          }
+        }
+        var merged = MLDoubleArray.Concat(doubleArrays);
+        return new Dataset(merged.DataHeader, merged.Data);
+      }
+    }
+  }
+}
Index: /branches/2913_MatlabScriptProblemInstanceProvider/HeuristicLab.Problems.Instances.DataAnalysis.Views/3.3/Regression/Matlab/MLTimeseriesLoader.cs
===================================================================
--- /branches/2913_MatlabScriptProblemInstanceProvider/HeuristicLab.Problems.Instances.DataAnalysis.Views/3.3/Regression/Matlab/MLTimeseriesLoader.cs	(revision 15926)
+++ /branches/2913_MatlabScriptProblemInstanceProvider/HeuristicLab.Problems.Instances.DataAnalysis.Views/3.3/Regression/Matlab/MLTimeseriesLoader.cs	(revision 15926)
@@ -0,0 +1,75 @@
+﻿using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+using System.Threading;
+using System.Threading.Tasks;
+using System.Windows.Forms;
+using HeuristicLab.Problems.DataAnalysis;
+using HeuristicLab.Problems.Instances.DataAnalysis.Regression.Matlab.Api;
+using HeuristicLab.Problems.Instances.DataAnalysis.Regression.Matlab.Api.Types;
+
+namespace HeuristicLab.Problems.Instances.DataAnalysis.Views.Regression.Matlab {
+  public partial class RegressionMatlabImportDialog {
+    private class MLTimeseriesLoader : MLVariablesLoader {
+      public MLTimeseriesLoader(RegressionMatlabImportDialog importDialog, CheckedListBox variablesListBox) 
+        : base(importDialog, variablesListBox, MLDatatype.Timeseries) {
+      }      
+
+      public override Dataset GetPreviewDataset(IMatlabConnector mlConnector, CancellationToken token) {
+        var timeseries = new List<MLTimeseries>();
+        foreach (MLVariableInfo item in _variablesListBox.CheckedItems.Cast<MLVariableInfo>().ToList()) {
+          if (token.IsCancellationRequested) {
+            return null;
+          }
+
+          if (item.Datatype == _mlDatatype) {
+            var val = mlConnector.GetTimeseries(item.VarName);
+            if (val != null) {
+              timeseries.Add(val);
+            }
+          }
+        }
+
+        var merged = new MLTimeseries(timeseries, token);
+        if (token.IsCancellationRequested) {
+          return null;
+        }
+        return new Dataset(GetVariableNames(merged), GetValuesForDataset(merged));
+      }      
+
+      /// <summary>
+      /// Returns a list with all selected variable names for the preview dataset.
+      /// </summary>
+      /// <param name="timeseries"></param>
+      /// <returns></returns>
+      private IEnumerable<string> GetVariableNames(MLTimeseries timeseries) {
+        IList<string> variableNamesWithType = timeseries.DataHeader.ToList();
+        variableNamesWithType.Insert(0, "time");
+        return variableNamesWithType;
+      }
+
+      /// <summary>
+      /// Returns a two dimensional double array which contains the values including the timestamps of the given timeseries.
+      /// Array[value, variable] 
+      /// If the amount of the data is too big, a OutOfMemoryException exception is being thrown. 
+      /// This exception is being cought and a message will be shown at the error message box.
+      /// </summary>
+      /// <param name="timeseries"></param>
+      /// <returns></returns>
+      private double[,] GetValuesForDataset(MLTimeseries timeseries) {
+        double[,] datasetValues = new double[timeseries.Count, timeseries.DataHeader.Length + 1];
+
+        int i = 0;
+        foreach (var item in timeseries.Data) {
+          datasetValues[i, 0] = item.Key;
+          for (int j = 1; j < datasetValues.GetLength(1); j++) {
+            datasetValues[i, j] = item.Value[j - 1];
+          }
+          i++;
+        }
+        return datasetValues;
+      }
+    }
+  }
+}
Index: /branches/2913_MatlabScriptProblemInstanceProvider/HeuristicLab.Problems.Instances.DataAnalysis.Views/3.3/Regression/Matlab/MLVariablesLoader.cs
===================================================================
--- /branches/2913_MatlabScriptProblemInstanceProvider/HeuristicLab.Problems.Instances.DataAnalysis.Views/3.3/Regression/Matlab/MLVariablesLoader.cs	(revision 15926)
+++ /branches/2913_MatlabScriptProblemInstanceProvider/HeuristicLab.Problems.Instances.DataAnalysis.Views/3.3/Regression/Matlab/MLVariablesLoader.cs	(revision 15926)
@@ -0,0 +1,58 @@
+﻿using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+using System.Threading;
+using System.Threading.Tasks;
+using System.Windows.Forms;
+using HeuristicLab.Common;
+using HeuristicLab.Problems.DataAnalysis;
+using HeuristicLab.Problems.Instances.DataAnalysis.Regression.Matlab.Api;
+using HeuristicLab.Problems.Instances.DataAnalysis.Regression.Matlab.Api.Types;
+
+namespace HeuristicLab.Problems.Instances.DataAnalysis.Views.Regression.Matlab {
+  public partial class RegressionMatlabImportDialog {
+    private abstract class MLVariablesLoader : IMLVariablesLoader {
+
+      protected IList<MLVariableInfo> _selectedVariables;
+
+      protected MLDatatype _mlDatatype;
+
+      protected CheckedListBox _variablesListBox;
+
+      public event EventHandler<EventArgs<int>> NumberOfSelectedVariablesChanged;
+
+      public IEnumerable<MLVariableInfo> SelectedVariables { get { return _selectedVariables; } }
+            
+      public MLVariablesLoader(RegressionMatlabImportDialog importDialog, CheckedListBox variablesListBox, MLDatatype mlDatatype) {
+        _variablesListBox = variablesListBox;
+        _mlDatatype = mlDatatype;
+        _selectedVariables = new List<MLVariableInfo>();
+
+        _variablesListBox.ItemCheck += (s, e) => importDialog.BeginInvoke((MethodInvoker)(() => CheckedItemsChanged(s, e)));
+      }
+      
+      #region Events
+      private void CheckedItemsChanged(object s, object e) {
+        _selectedVariables.Clear();
+        foreach (MLVariableInfo item in _variablesListBox.CheckedItems) {
+          if (item.Datatype == _mlDatatype) {
+            _selectedVariables.Add(item);
+          }
+        }
+        NumberOfSelectedVariablesChanged?.Invoke(this, new EventArgs<int>(_selectedVariables.Count));
+      }
+      #endregion
+
+      public abstract Dataset GetPreviewDataset(IMatlabConnector mlConnector, CancellationToken token);
+
+      public void DisplayVariables(IEnumerable<MLVariableInfo> variables) {
+        foreach (var item in variables) {
+          if (item.Datatype == _mlDatatype) {
+            _variablesListBox.Items.Add(item, false);
+          }
+        }
+      }
+    }
+  }
+}
Index: /branches/2913_MatlabScriptProblemInstanceProvider/HeuristicLab.Problems.Instances.DataAnalysis.Views/3.3/Regression/Matlab/RegressionMatlabImportDialog.Designer.cs
===================================================================
--- /branches/2913_MatlabScriptProblemInstanceProvider/HeuristicLab.Problems.Instances.DataAnalysis.Views/3.3/Regression/Matlab/RegressionMatlabImportDialog.Designer.cs	(revision 15925)
+++ /branches/2913_MatlabScriptProblemInstanceProvider/HeuristicLab.Problems.Instances.DataAnalysis.Views/3.3/Regression/Matlab/RegressionMatlabImportDialog.Designer.cs	(revision 15926)
@@ -32,6 +32,7 @@
             this.ToolTip = new System.Windows.Forms.ToolTip(this.components);
             this.ProblemDataSettingsGroupBox = new System.Windows.Forms.GroupBox();
+            this.ErrorTextBox = new System.Windows.Forms.TextBox();
+            this.label1 = new System.Windows.Forms.Label();
             this.TargetVariableComboBox = new System.Windows.Forms.ComboBox();
-            this.ErrorTextBox = new System.Windows.Forms.TextBox();
             this.PreviewLabel = new System.Windows.Forms.Label();
             this.TestLabel = new System.Windows.Forms.Label();
@@ -42,11 +43,17 @@
             this.OkButton = new System.Windows.Forms.Button();
             this.MatlabVariablesGroupBox = new System.Windows.Forms.GroupBox();
+            this.DatatypeSelectorTabControl = new System.Windows.Forms.TabControl();
+            this.Timeseries = new System.Windows.Forms.TabPage();
+            this.TimeseriesListBox = new System.Windows.Forms.CheckedListBox();
+            this.DoubleArrays = new System.Windows.Forms.TabPage();
+            this.DoubleArraysListBox = new System.Windows.Forms.CheckedListBox();
             this.LoadValuesButton = new System.Windows.Forms.Button();
-            this.VariablesListBox = new System.Windows.Forms.CheckedListBox();
-            this.label1 = new System.Windows.Forms.Label();
             this.StatusLabel = new System.Windows.Forms.Label();
             this.ProblemDataSettingsGroupBox.SuspendLayout();
             ((System.ComponentModel.ISupportInitialize)(this.TrainingTestTrackBar)).BeginInit();
             this.MatlabVariablesGroupBox.SuspendLayout();
+            this.DatatypeSelectorTabControl.SuspendLayout();
+            this.Timeseries.SuspendLayout();
+            this.DoubleArrays.SuspendLayout();
             this.SuspendLayout();
             // 
@@ -97,23 +104,15 @@
             this.ProblemDataSettingsGroupBox.Controls.Add(this.TrainingLabel);
             this.ProblemDataSettingsGroupBox.Controls.Add(this.TrainingTestTrackBar);
-            this.ProblemDataSettingsGroupBox.Location = new System.Drawing.Point(12, 191);
+            this.ProblemDataSettingsGroupBox.Location = new System.Drawing.Point(12, 210);
             this.ProblemDataSettingsGroupBox.Name = "ProblemDataSettingsGroupBox";
-            this.ProblemDataSettingsGroupBox.Size = new System.Drawing.Size(447, 225);
+            this.ProblemDataSettingsGroupBox.Size = new System.Drawing.Size(447, 258);
             this.ProblemDataSettingsGroupBox.TabIndex = 20;
             this.ProblemDataSettingsGroupBox.TabStop = false;
             this.ProblemDataSettingsGroupBox.Text = "ProblemData Settings";
             // 
-            // TargetVariableComboBox
-            // 
-            this.TargetVariableComboBox.BackColor = System.Drawing.SystemColors.Control;
-            this.TargetVariableComboBox.FormattingEnabled = true;
-            this.TargetVariableComboBox.Location = new System.Drawing.Point(256, 19);
-            this.TargetVariableComboBox.Name = "TargetVariableComboBox";
-            this.TargetVariableComboBox.Size = new System.Drawing.Size(185, 21);
-            this.TargetVariableComboBox.TabIndex = 8;
-            // 
             // ErrorTextBox
             // 
-            this.ErrorTextBox.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left) 
+            this.ErrorTextBox.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)));
             this.ErrorTextBox.Location = new System.Drawing.Point(6, 15);
@@ -121,7 +120,25 @@
             this.ErrorTextBox.Name = "ErrorTextBox";
             this.ErrorTextBox.ReadOnly = true;
-            this.ErrorTextBox.Size = new System.Drawing.Size(435, 204);
+            this.ErrorTextBox.Size = new System.Drawing.Size(435, 237);
             this.ErrorTextBox.TabIndex = 0;
             this.ErrorTextBox.Text = "Open a Matlab File";
+            // 
+            // label1
+            // 
+            this.label1.AutoSize = true;
+            this.label1.Location = new System.Drawing.Point(9, 22);
+            this.label1.Name = "label1";
+            this.label1.Size = new System.Drawing.Size(82, 13);
+            this.label1.TabIndex = 9;
+            this.label1.Text = "Target Variable:";
+            // 
+            // TargetVariableComboBox
+            // 
+            this.TargetVariableComboBox.BackColor = System.Drawing.SystemColors.Control;
+            this.TargetVariableComboBox.FormattingEnabled = true;
+            this.TargetVariableComboBox.Location = new System.Drawing.Point(97, 19);
+            this.TargetVariableComboBox.Name = "TargetVariableComboBox";
+            this.TargetVariableComboBox.Size = new System.Drawing.Size(185, 21);
+            this.TargetVariableComboBox.TabIndex = 8;
             // 
             // PreviewLabel
@@ -156,5 +173,5 @@
             this.PreviewDatasetMatrix.ShowRowsAndColumnsTextBox = false;
             this.PreviewDatasetMatrix.ShowStatisticalInformation = false;
-            this.PreviewDatasetMatrix.Size = new System.Drawing.Size(435, 111);
+            this.PreviewDatasetMatrix.Size = new System.Drawing.Size(435, 144);
             this.PreviewDatasetMatrix.TabIndex = 0;
             // 
@@ -185,5 +202,5 @@
             this.CancellationButton.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
             this.CancellationButton.DialogResult = System.Windows.Forms.DialogResult.Cancel;
-            this.CancellationButton.Location = new System.Drawing.Point(384, 422);
+            this.CancellationButton.Location = new System.Drawing.Point(384, 474);
             this.CancellationButton.Name = "CancellationButton";
             this.CancellationButton.Size = new System.Drawing.Size(75, 23);
@@ -197,5 +214,5 @@
             this.OkButton.DialogResult = System.Windows.Forms.DialogResult.OK;
             this.OkButton.Enabled = false;
-            this.OkButton.Location = new System.Drawing.Point(303, 422);
+            this.OkButton.Location = new System.Drawing.Point(303, 474);
             this.OkButton.Name = "OkButton";
             this.OkButton.Size = new System.Drawing.Size(75, 23);
@@ -206,18 +223,74 @@
             // MatlabVariablesGroupBox
             // 
+            this.MatlabVariablesGroupBox.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left) 
+            | System.Windows.Forms.AnchorStyles.Right)));
+            this.MatlabVariablesGroupBox.Controls.Add(this.DatatypeSelectorTabControl);
             this.MatlabVariablesGroupBox.Controls.Add(this.LoadValuesButton);
-            this.MatlabVariablesGroupBox.Controls.Add(this.VariablesListBox);
             this.MatlabVariablesGroupBox.Location = new System.Drawing.Point(12, 32);
             this.MatlabVariablesGroupBox.Name = "MatlabVariablesGroupBox";
-            this.MatlabVariablesGroupBox.Size = new System.Drawing.Size(447, 153);
+            this.MatlabVariablesGroupBox.Size = new System.Drawing.Size(447, 172);
             this.MatlabVariablesGroupBox.TabIndex = 22;
             this.MatlabVariablesGroupBox.TabStop = false;
             this.MatlabVariablesGroupBox.Text = "Matlab variables";
             // 
+            // DatatypeSelectorTabControl
+            // 
+            this.DatatypeSelectorTabControl.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left) 
+            | System.Windows.Forms.AnchorStyles.Right)));
+            this.DatatypeSelectorTabControl.Controls.Add(this.Timeseries);
+            this.DatatypeSelectorTabControl.Controls.Add(this.DoubleArrays);
+            this.DatatypeSelectorTabControl.Location = new System.Drawing.Point(6, 19);
+            this.DatatypeSelectorTabControl.Name = "DatatypeSelectorTabControl";
+            this.DatatypeSelectorTabControl.SelectedIndex = 0;
+            this.DatatypeSelectorTabControl.Size = new System.Drawing.Size(435, 124);
+            this.DatatypeSelectorTabControl.TabIndex = 24;
+            // 
+            // Timeseries
+            // 
+            this.Timeseries.Controls.Add(this.TimeseriesListBox);
+            this.Timeseries.Location = new System.Drawing.Point(4, 22);
+            this.Timeseries.Name = "Timeseries";
+            this.Timeseries.Padding = new System.Windows.Forms.Padding(3);
+            this.Timeseries.Size = new System.Drawing.Size(427, 98);
+            this.Timeseries.TabIndex = 0;
+            this.Timeseries.Text = "Timeseries";
+            this.Timeseries.UseVisualStyleBackColor = true;
+            // 
+            // TimeseriesListBox
+            // 
+            this.TimeseriesListBox.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left) 
+            | System.Windows.Forms.AnchorStyles.Right)));
+            this.TimeseriesListBox.FormattingEnabled = true;
+            this.TimeseriesListBox.Location = new System.Drawing.Point(0, 2);
+            this.TimeseriesListBox.Name = "TimeseriesListBox";
+            this.TimeseriesListBox.Size = new System.Drawing.Size(424, 94);
+            this.TimeseriesListBox.TabIndex = 23;
+            // 
+            // DoubleArrays
+            // 
+            this.DoubleArrays.Controls.Add(this.DoubleArraysListBox);
+            this.DoubleArrays.Location = new System.Drawing.Point(4, 22);
+            this.DoubleArrays.Name = "DoubleArrays";
+            this.DoubleArrays.Padding = new System.Windows.Forms.Padding(3);
+            this.DoubleArrays.Size = new System.Drawing.Size(427, 98);
+            this.DoubleArrays.TabIndex = 1;
+            this.DoubleArrays.Text = "Double Arrays";
+            this.DoubleArrays.UseVisualStyleBackColor = true;
+            // 
+            // DoubleArraysListBox
+            // 
+            this.DoubleArraysListBox.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left) 
+            | System.Windows.Forms.AnchorStyles.Right)));
+            this.DoubleArraysListBox.FormattingEnabled = true;
+            this.DoubleArraysListBox.Location = new System.Drawing.Point(0, 4);
+            this.DoubleArraysListBox.Name = "DoubleArraysListBox";
+            this.DoubleArraysListBox.Size = new System.Drawing.Size(425, 94);
+            this.DoubleArraysListBox.TabIndex = 24;
+            // 
             // LoadValuesButton
             // 
             this.LoadValuesButton.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
             this.LoadValuesButton.Enabled = false;
-            this.LoadValuesButton.Location = new System.Drawing.Point(366, 124);
+            this.LoadValuesButton.Location = new System.Drawing.Point(366, 143);
             this.LoadValuesButton.Name = "LoadValuesButton";
             this.LoadValuesButton.Size = new System.Drawing.Size(75, 23);
@@ -226,26 +299,9 @@
             this.LoadValuesButton.UseVisualStyleBackColor = true;
             // 
-            // VariablesListBox
-            // 
-            this.VariablesListBox.FormattingEnabled = true;
-            this.VariablesListBox.Location = new System.Drawing.Point(6, 18);
-            this.VariablesListBox.Name = "VariablesListBox";
-            this.VariablesListBox.Size = new System.Drawing.Size(435, 94);
-            this.VariablesListBox.TabIndex = 22;
-            // 
-            // label1
-            // 
-            this.label1.AutoSize = true;
-            this.label1.Location = new System.Drawing.Point(168, 22);
-            this.label1.Name = "label1";
-            this.label1.Size = new System.Drawing.Size(82, 13);
-            this.label1.TabIndex = 9;
-            this.label1.Text = "Target Variable:";
-            // 
             // StatusLabel
             // 
             this.StatusLabel.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)));
             this.StatusLabel.AutoSize = true;
-            this.StatusLabel.Location = new System.Drawing.Point(9, 427);
+            this.StatusLabel.Location = new System.Drawing.Point(9, 479);
             this.StatusLabel.Name = "StatusLabel";
             this.StatusLabel.Size = new System.Drawing.Size(37, 13);
@@ -257,5 +313,5 @@
             this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
             this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
-            this.ClientSize = new System.Drawing.Size(471, 457);
+            this.ClientSize = new System.Drawing.Size(471, 509);
             this.Controls.Add(this.StatusLabel);
             this.Controls.Add(this.MatlabVariablesGroupBox);
@@ -273,4 +329,7 @@
             ((System.ComponentModel.ISupportInitialize)(this.TrainingTestTrackBar)).EndInit();
             this.MatlabVariablesGroupBox.ResumeLayout(false);
+            this.DatatypeSelectorTabControl.ResumeLayout(false);
+            this.Timeseries.ResumeLayout(false);
+            this.DoubleArrays.ResumeLayout(false);
             this.ResumeLayout(false);
             this.PerformLayout();
@@ -296,8 +355,12 @@
     private System.Windows.Forms.GroupBox MatlabVariablesGroupBox;
     protected System.Windows.Forms.Button LoadValuesButton;
-    private System.Windows.Forms.CheckedListBox VariablesListBox;
     private System.Windows.Forms.ComboBox TargetVariableComboBox;
     protected System.Windows.Forms.Label label1;
     protected System.Windows.Forms.Label StatusLabel;
+    private System.Windows.Forms.TabControl DatatypeSelectorTabControl;
+    private System.Windows.Forms.TabPage Timeseries;
+    private System.Windows.Forms.CheckedListBox TimeseriesListBox;
+    private System.Windows.Forms.TabPage DoubleArrays;
+    private System.Windows.Forms.CheckedListBox DoubleArraysListBox;
   }
 }
Index: /branches/2913_MatlabScriptProblemInstanceProvider/HeuristicLab.Problems.Instances.DataAnalysis.Views/3.3/Regression/Matlab/RegressionMatlabImportDialog.cs
===================================================================
--- /branches/2913_MatlabScriptProblemInstanceProvider/HeuristicLab.Problems.Instances.DataAnalysis.Views/3.3/Regression/Matlab/RegressionMatlabImportDialog.cs	(revision 15925)
+++ /branches/2913_MatlabScriptProblemInstanceProvider/HeuristicLab.Problems.Instances.DataAnalysis.Views/3.3/Regression/Matlab/RegressionMatlabImportDialog.cs	(revision 15926)
@@ -19,9 +19,17 @@
 namespace HeuristicLab.Problems.Instances.DataAnalysis.Views.Regression.Matlab {
   public partial class RegressionMatlabImportDialog : Form {
+    private const int TAB_INDEX_TIMESERIES = 0;
+    private const int TAB_INDEX_DOUBLE_ARRAYS = 1;
+
     private IMatlabConnector _mlConnector;
+
+    private IMLVariablesLoader _variablesLoader;
+    private IMLVariablesLoader _timeseriesLoader;
+    private IMLVariablesLoader _doubleArraysLoader;
+
+    private CancellationTokenSource _cts = new CancellationTokenSource();
+
     public event EventHandler<EventArgs<string>> StatusChangedEvent;
     public event EventHandler<EventArgs<string>> ErrorOccuredEvent;
-
-
 
     /// <summary>
@@ -49,9 +57,10 @@
     }
 
-    private IList<KeyValuePair<string, MLDatatype>> _selectedVariables;
-
-    public IEnumerable<KeyValuePair<string, MLDatatype>> SelectedVariables {
+    private IList<MLVariableInfo> _selectedTimeseries;
+    private IList<MLVariableInfo> _selectedDoubleArrays;
+
+    public IEnumerable<MLVariableInfo> SelectedVariables {
       get {
-        return _selectedVariables;
+        return _variablesLoader.SelectedVariables;
       }
     }
@@ -60,12 +69,16 @@
       InitializeComponent();
 
-      _selectedVariables = new List<KeyValuePair<string, MLDatatype>>();
+      _selectedTimeseries = new List<MLVariableInfo>();
+      _selectedDoubleArrays = new List<MLVariableInfo>();
       _values = new Dataset();
 
       this.FormClosed += (s, e) => DisposeMatlabConnector();
       OpenFileButton.Click += OpenFileButtonClick;
-      VariablesListBox.ItemCheck += (s, e) => BeginInvoke((MethodInvoker)(() => CheckedItemsChanged(s, e)));
+
+      DatatypeSelectorTabControl.SelectedIndexChanged += (s, e) => BeginInvoke((MethodInvoker)(() => DatatypeSelectorTabControlTabIndexChanged(s, e)));
+
       LoadValuesButton.Click += LoadValuesButtonClick;
       TrainingTestTrackBar.ValueChanged += TrainingTestTrackBarValueChanged;
+
       StatusChangedEvent += (s, e) => BeginInvoke((MethodInvoker)(() => StatusLabel.Text = e.Value));
       ErrorOccuredEvent += (s, e) => BeginInvoke((MethodInvoker)(() => {
@@ -74,20 +87,36 @@
         ErrorTextBox.Visible = true;
       }));
-    }
-
-    private void CheckedItemsChanged(object sender, ItemCheckEventArgs e) {
-      _selectedVariables.Clear();
-      foreach (KeyValuePair<string, MLDatatype> item in VariablesListBox.CheckedItems) {
-        if (item.Value == MLDatatype.Timeseries) {
-          _selectedVariables.Add(item);
-        }
-      }
-      LoadValuesButton.Enabled = VariablesListBox.CheckedIndices.Count > 0;
-    }
-
-    #region Events
-
+
+      _timeseriesLoader = new MLTimeseriesLoader(this, TimeseriesListBox);
+      _timeseriesLoader.NumberOfSelectedVariablesChanged += NumberOfSelectedVariablesChanged;
+      _doubleArraysLoader = new MLDoubleArrayLoader(this, DoubleArraysListBox);
+      _doubleArraysLoader.NumberOfSelectedVariablesChanged += NumberOfSelectedVariablesChanged;
+
+      _variablesLoader = _timeseriesLoader;
+
+    }
+
+    #region Methods for Events
+
+    private void NumberOfSelectedVariablesChanged(object s, EventArgs<int> e) {
+      LoadValuesButton.Enabled = e.Value > 0;
+    }
+
+    private void DatatypeSelectorTabControlTabIndexChanged(object s, EventArgs e) {
+      switch (DatatypeSelectorTabControl.SelectedIndex) {
+        case TAB_INDEX_TIMESERIES:
+          _variablesLoader = _timeseriesLoader;
+          break;
+        case TAB_INDEX_DOUBLE_ARRAYS:
+          _variablesLoader = _doubleArraysLoader;
+          break;
+      }
+
+      LoadValuesButton.Enabled = _variablesLoader.SelectedVariables.Count() > 0;
+    }
 
     private void LoadValuesButtonClick(object sender, EventArgs e) {
+      _cts.Cancel();
+      _cts = new CancellationTokenSource();
       LoadValuesAsync();
     }
@@ -106,5 +135,5 @@
     }
     #endregion
-    
+
     /// <summary>
     /// Fires the ErrorOccuredEvent with the given text message.
@@ -127,4 +156,5 @@
       if (_mlConnector == null) {
         _mlConnector = MatlabApiFactory.CreateMatlabConnector();
+        _mlConnector.ErrorOccuredEvent += ErrorOccured;
       }
     }
@@ -141,5 +171,4 @@
 
 
-
     /// <summary>
     /// This method reads all available variables form the selected matlab scirpt and puts them into the list view.
@@ -147,5 +176,4 @@
     private async void GetVariableNamesAsync() {
       UpdateStatus("Opening Matlab");
-
       var path = openFileDialog.FileName;
       ProblemTextBox.Text = path;
@@ -156,41 +184,37 @@
 
       UpdateStatus("Loading variable names");
-      var variablesListBoxItems = VariablesListBox.Items;
-      variablesListBoxItems.Clear();
-      foreach (var item in variables) {
-        variablesListBoxItems.Add(item, false);
-      }
+      _timeseriesLoader.DisplayVariables(variables);
+      _doubleArraysLoader.DisplayVariables(variables);
       UpdateStatus("Done");
     }
 
-    /// <summary>
-    /// Loads the values of the selected timeseries values and displays them at the preview control.
-    /// </summary>
     private async void LoadValuesAsync() {
+      UpdateStatus("Loading values from Matlab");
       try {
-        PreviewDatasetMatrix.Content = new Dataset();
-
-        UpdateStatus("Loading values from Matlab");
-        var vals = await Task.Run<List<MLTimeseries>>(() => {
-          var values = new List<MLTimeseries>();
-          foreach (KeyValuePair<string, MLDatatype> item in VariablesListBox.CheckedItems) {
-            if (item.Value == MLDatatype.Timeseries) {
-              var val = _mlConnector.GetTimeseries(item.Key);
-              if (val != null) {
-                values.Add(val);
-              }
-            }
-          }
-          return values;
-        });
-
-        UpdateStatus("Converting values");
-        DisplayLoadedValuesAsync(await Task.Run<MLTimeseries>(() => new MLTimeseries(vals)));
-        ErrorTextBox.Text = String.Empty;
-        ErrorTextBox.Visible = false;
-        OkButton.Enabled = true;
+        // As there can be a huge amount of data, it should be freed before reallocating it.
+        OkButton.Enabled = false;
+        _values = new Dataset();
+        PreviewDatasetMatrix.Content = _values;
+        TargetVariableComboBox.DataSource = new List<string>();
+        TargetVariableComboBox.SelectedText = "";
+        GC.Collect();
+        var token = _cts.Token;
+        var ds = await Task.Run<Dataset>(() => _variablesLoader.GetPreviewDataset(_mlConnector, token), token);
+        GC.Collect();
+
+        if (ds != null) {
+          _values = ds;
+          PreviewDatasetMatrix.Content = _values;
+          TargetVariableComboBox.DataSource = _values.VariableNames;
+
+          ErrorTextBox.Text = String.Empty;
+          ErrorTextBox.Visible = false;
+          OkButton.Enabled = true;
+        }        
       } catch (Exception ex) {
         if (ex is IOException || ex is InvalidOperationException || ex is ArgumentException) {
           ErrorOccured(ex.Message);
+        } else if (ex is OutOfMemoryException) {
+          ErrorOccured(ex.Message + " Amount of the given data is too big.");
         } else {
           throw;
@@ -199,65 +223,4 @@
       UpdateStatus("Done");
     }
-
-    /// <summary>
-    /// Displays the values of a given timeseries at the preview dataset matrix.
-    /// </summary>
-    /// <param name="timeseries"></param>
-    private async void DisplayLoadedValuesAsync(MLTimeseries timeseries) {
-      PreviewDatasetMatrix.Content = null;
-      IEnumerable<string> variableNamesWithType = GetVariableNamesWithType(timeseries);
-      var values = await Task.Run<double[,]>(() => GetValuesForDataset(timeseries));
-      _values = new Dataset(variableNamesWithType, values);
-      PreviewDatasetMatrix.Content = _values;
-      SetPossibleTargetVariables(timeseries);
-    }
-
-    /// <summary>
-    /// Sets the entries of the combobox for the target variable.
-    /// </summary>
-    /// <param name="timeseries"></param>
-    protected void SetPossibleTargetVariables(MLTimeseries timeseries) {
-      if (timeseries != null) {
-        TargetVariableComboBox.DataSource = timeseries.DataHeader;
-      }
-    }
-
-    /// <summary>
-    /// Returns a list with all selected variable names for the preview dataset.
-    /// </summary>
-    /// <param name="timeseries"></param>
-    /// <returns></returns>
-    private IEnumerable<string> GetVariableNamesWithType(MLTimeseries timeseries) {
-      IList<string> variableNamesWithType = timeseries.DataHeader.ToList();
-      variableNamesWithType.Insert(0, "time");
-      return variableNamesWithType;
-    }
-
-    /// <summary>
-    /// Returns a two dimensional double array which contains the values including the timestamps of the given timeseries.
-    /// Array[value, variable] 
-    /// If the amount of the data is too big, a OutOfMemoryException exception is being thrown. 
-    /// This exception is being cought and a message will be shown at the error message box.
-    /// </summary>
-    /// <param name="timeseries"></param>
-    /// <returns></returns>
-    private double[,] GetValuesForDataset(MLTimeseries timeseries) {
-      try {
-        double[,] datasetValues = new double[timeseries.Count, timeseries.DataHeader.Length + 1];
-
-        int i = 0;
-        foreach (var item in timeseries.Data) {
-          datasetValues[i, 0] = item.Key;
-          for (int j = 1; j < datasetValues.GetLength(1); j++) {
-            datasetValues[i, j] = item.Value[j - 1];
-          }
-          i++;
-        }
-        return datasetValues;
-      } catch (OutOfMemoryException ex) {
-        ErrorOccured(ex.Message + " Amount of the given data is too big.");
-      }
-      return new double[0, timeseries.DataHeader.Length + 1];
-    }
   }
 }
Index: /branches/2913_MatlabScriptProblemInstanceProvider/HeuristicLab.Problems.Instances.DataAnalysis/3.3/HeuristicLab.Problems.Instances.DataAnalysis-3.3.csproj
===================================================================
--- /branches/2913_MatlabScriptProblemInstanceProvider/HeuristicLab.Problems.Instances.DataAnalysis/3.3/HeuristicLab.Problems.Instances.DataAnalysis-3.3.csproj	(revision 15925)
+++ /branches/2913_MatlabScriptProblemInstanceProvider/HeuristicLab.Problems.Instances.DataAnalysis/3.3/HeuristicLab.Problems.Instances.DataAnalysis-3.3.csproj	(revision 15926)
@@ -165,4 +165,5 @@
     <Compile Include="Regression\Matlab\Api\MatlabApiFactory.cs" />
     <Compile Include="Regression\Matlab\Api\MatlabConnector.cs" />
+    <Compile Include="Regression\Matlab\Api\Types\MLVariableInfo.cs" />
     <Compile Include="Regression\Matlab\RegressionMatlabImportType.cs" />
     <Compile Include="Regression\Matlab\RegressionMatlabInstanceProvider.cs" />
Index: /branches/2913_MatlabScriptProblemInstanceProvider/HeuristicLab.Problems.Instances.DataAnalysis/3.3/Regression/Matlab/Api/IMatlabConnector.cs
===================================================================
--- /branches/2913_MatlabScriptProblemInstanceProvider/HeuristicLab.Problems.Instances.DataAnalysis/3.3/Regression/Matlab/Api/IMatlabConnector.cs	(revision 15925)
+++ /branches/2913_MatlabScriptProblemInstanceProvider/HeuristicLab.Problems.Instances.DataAnalysis/3.3/Regression/Matlab/Api/IMatlabConnector.cs	(revision 15926)
@@ -9,4 +9,6 @@
 namespace HeuristicLab.Problems.Instances.DataAnalysis.Regression.Matlab.Api {
   public interface IMatlabConnector : IDisposable {
+    event Action<string> ErrorOccuredEvent;
+
     /// <summary>
     /// Executes a given matlab script.
@@ -25,5 +27,5 @@
     /// </summary>
     /// <returns></returns>
-    IDictionary<string, MLDatatype> GetVariablesFromScript(string script);
+    IEnumerable<MLVariableInfo> GetVariablesFromScript(string script);
 
     /// <summary>
@@ -47,4 +49,11 @@
     /// <returns></returns>
     MLDouble GetDouble(string varName);
+
+    /// <summary>
+    /// 
+    /// </summary>
+    /// <param name="varName"></param>
+    /// <returns></returns>
+    MLDoubleArray GetDoubleArray(string varName);
   }
 }
Index: /branches/2913_MatlabScriptProblemInstanceProvider/HeuristicLab.Problems.Instances.DataAnalysis/3.3/Regression/Matlab/Api/MatlabConnector.cs
===================================================================
--- /branches/2913_MatlabScriptProblemInstanceProvider/HeuristicLab.Problems.Instances.DataAnalysis/3.3/Regression/Matlab/Api/MatlabConnector.cs	(revision 15925)
+++ /branches/2913_MatlabScriptProblemInstanceProvider/HeuristicLab.Problems.Instances.DataAnalysis/3.3/Regression/Matlab/Api/MatlabConnector.cs	(revision 15926)
@@ -31,4 +31,7 @@
     private MLApp.MLApp matLabApi;
     private string workspace;
+    private object locker = new object();
+
+    public event Action<string> ErrorOccuredEvent;
 
     public MatlabConnector(bool showcommandWindow = false, string workspace = "base") {
@@ -68,7 +71,13 @@
 
 
-    public IDictionary<string, MLDatatype> GetVariablesFromScript(string script) {
-      var variables = new Dictionary<string, MLDatatype>();
-      ExecuteScript(script);
+    public IEnumerable<MLVariableInfo> GetVariablesFromScript(string script) {
+      var variables = new List<MLVariableInfo>();
+      try {
+        ExecuteScript(script);
+      } catch(InvalidOperationException ex) {
+        if (ErrorOccuredEvent != null) {
+          ErrorOccuredEvent.Invoke(ex.Message);
+        }
+      }
 
       Execute("variables=whos();nrOfVariables=size(variables)");
@@ -77,28 +86,62 @@
       for (int i = 1; i <= len; i++) {
         var varName = GetVariable(string.Format("variables({0}).name", i)) as string;
-        var varSize = GetVariable(string.Format("variables({0}).size", i));
+        var varSize = GetVariable(string.Format("variables({0}).size", i)) as double[,];
         var varClass = GetVariable(string.Format("variables({0}).class", i)) as string;
-        // At the moment only timeseries are supported.
-        if (varClass == "timeseries") {
-          variables.Add(varName, MLDatatype.Timeseries);
-        }
+        
+        GetVariablesFromScriptRec(variables, varName, varSize, varClass);
       }
 
       return variables;
     }
-    
+
+    private void GetVariablesFromScriptRec(IList<MLVariableInfo> variables, string varName, double[,] varSize, string varClass) {
+      var variable = new MLVariableInfo() {
+        VarName = varName,
+        Row = varSize[0, 0],
+        Column = varSize[0, 1]
+      };
+      if (varClass == "timeseries") {
+        variable.Datatype = MLDatatype.Timeseries;
+        variables.Add(variable);
+      } else if (varClass == "double") {
+        if (variable.Row == 1 && variable.Column == 1) {
+          variable.Datatype = MLDatatype.Double;
+        } else {
+          variable.Datatype = MLDatatype.DoubleArray;
+        }
+        variables.Add(variable);
+      } else if (varClass == "struct") {
+        Execute(string.Format("mlFieldNames = fieldnames({0})", varName));
+        var fields = GetVariable("mlFieldNames") as object[,];
+
+        for (int i = 0; i < fields.GetLength(0); i++) {
+          var newVarName = string.Format("{0}.{1}", varName, fields[i, 0] as string);
+          Execute(string.Format("mlClass = class({0}); mlSize = size({0});", newVarName));
+          var newVarClass = GetVariable("mlClass") as string;
+          var newVarSize = GetVariable("mlSize") as double[,];
+          GetVariablesFromScriptRec(variables, newVarName, newVarSize, newVarClass);
+        }
+      }
+    }
 
     public MLTimeseries GetTimeseries(string varName) {
-      object times = GetVariable(varName + ".Time");
-      object data = GetVariable(varName + ".Data");
-      if (times == null || data == null) {
-        return null;
+      lock (locker) {
+        object times = GetVariable(varName + ".Time");
+        object data = GetVariable(varName + ".Data");
+
+        if (times == null || data == null) {
+          return null;
+        }
+        return new MLTimeseries(varName, times, data);
       }
-
-      return new MLTimeseries(varName, times, data);
     }
 
     public MLDouble GetDouble(string varName) {
       return new MLDouble(varName, GetVariable(varName));
+    }
+
+
+    public MLDoubleArray GetDoubleArray(string varName) {
+      return new MLDoubleArray(varName, GetVariable(varName));
     }
 
@@ -142,5 +185,4 @@
       }
     }
-
   }
 }
Index: /branches/2913_MatlabScriptProblemInstanceProvider/HeuristicLab.Problems.Instances.DataAnalysis/3.3/Regression/Matlab/Api/Types/MLDatatype.cs
===================================================================
--- /branches/2913_MatlabScriptProblemInstanceProvider/HeuristicLab.Problems.Instances.DataAnalysis/3.3/Regression/Matlab/Api/Types/MLDatatype.cs	(revision 15925)
+++ /branches/2913_MatlabScriptProblemInstanceProvider/HeuristicLab.Problems.Instances.DataAnalysis/3.3/Regression/Matlab/Api/Types/MLDatatype.cs	(revision 15926)
@@ -9,5 +9,7 @@
         Double,
         DoubleArray,
-        Timeseries
+        Timeseries,
+        Struct,
+        Undefinded
     }
 }
Index: /branches/2913_MatlabScriptProblemInstanceProvider/HeuristicLab.Problems.Instances.DataAnalysis/3.3/Regression/Matlab/Api/Types/MLDoubleArray.cs
===================================================================
--- /branches/2913_MatlabScriptProblemInstanceProvider/HeuristicLab.Problems.Instances.DataAnalysis/3.3/Regression/Matlab/Api/Types/MLDoubleArray.cs	(revision 15925)
+++ /branches/2913_MatlabScriptProblemInstanceProvider/HeuristicLab.Problems.Instances.DataAnalysis/3.3/Regression/Matlab/Api/Types/MLDoubleArray.cs	(revision 15926)
@@ -27,11 +27,11 @@
       Name = string.Format("{0};{1}", a1.Name, a2.Name);
 
-      if (!ConcatFeasible(a1, a2)) {
+      if (!ConcatIsPossible(a1, a2)) {
         throw new ArgumentException(string.Format("Cannot concat {0} and {1}. Different number of rows.", a1.Name, a2.Name));
       }
 
-      var numberOfColumns = a1.Columns + a2.Columns;
-      _dataHeaders = new string[numberOfColumns];
-      for (int i = 0; i < numberOfColumns; i++) {
+      var columns = a1.Columns + a2.Columns;
+      _dataHeaders = new string[columns];
+      for (int i = 0; i < columns; i++) {
         if (i < a1.Columns) {
           _dataHeaders[i] = a1.DataHeader[i];
@@ -41,11 +41,44 @@
       }
 
-      Data = new double[a1.Rows, numberOfColumns];
+      Data = new double[a1.Rows, columns];
       for (int i = 0; i < a1.Rows; i++) {
-        for (int j = 0; j < numberOfColumns; j++) {
+        for (int j = 0; j < columns; j++) {
           if (j < a1.Columns) {
             Data[i, j] = a1.Data[i, j];
           } else {
             Data[i, j] = a1.Data[i, j - a1.Columns];
+          }
+        }
+      }
+    }
+
+    private MLDoubleArray(IEnumerable<MLDoubleArray> arrays) {
+      StringBuilder sb = new StringBuilder();
+      foreach (var array in arrays) {
+        sb.Append(array.Name + ";");
+      }
+      Name = sb.ToString();
+
+      var columns = 0;
+      foreach (var array in arrays) {
+        columns += array.Columns;
+      }
+
+      var dataHeaders = new List<string>();
+      foreach (var array in arrays) {
+        foreach (var header in array.DataHeader) {
+          dataHeaders.Add(header);
+        }
+      }
+      _dataHeaders = dataHeaders.ToArray();
+
+      var rows = arrays.First().Rows;
+      Data = new double[rows, columns];
+      for (int i = 0; i < rows; i++) {
+        var j = 0;
+        foreach (var array in arrays) {
+          for (int k = 0; k < array.Columns; k++) {
+            Data[i, j] = array.Data[i, k];
+            j++;
           }
         }
@@ -57,5 +90,5 @@
     /// <summary>
     /// Concats two given MLDoubleArrays if their number of rows equals.
-    /// If they can't be concated, this method returns null.
+    /// If throws an InvalidOperationException if they can't be concatenated
     /// </summary>
     /// <param name="a1"></param>
@@ -63,12 +96,32 @@
     /// <returns></returns>
     public static MLDoubleArray Concat(MLDoubleArray a1, MLDoubleArray a2) {
-      if (ConcatFeasible(a1, a2)) {
-        return null;
+      if (ConcatIsPossible(a1, a2)) {
+        throw new InvalidOperationException("Concatination is not possible because of different different number of their rows.");
       }
       return new MLDoubleArray(a1, a2);
     }
 
-    public static bool ConcatFeasible(MLDoubleArray a1, MLDoubleArray a2) {
+    public static MLDoubleArray Concat(IEnumerable<MLDoubleArray> arrays) {
+      if (arrays.Count() < 1) {
+        throw new ArgumentException("Given number of MLDoubleArrays is 0");
+      }
+      if (!ConcatIsPossible(arrays)) {
+        throw new InvalidOperationException("Concatenation is not possible because of different different number of their rows.");
+      }
+      return new MLDoubleArray(arrays);
+    }
+
+    public static bool ConcatIsPossible(MLDoubleArray a1, MLDoubleArray a2) {
       return a1.Rows == a2.Rows;
+    }
+
+    public static bool ConcatIsPossible(IEnumerable<MLDoubleArray> arrays) {
+      var first = arrays.First();
+      foreach (var array in arrays) {
+        if (!ConcatIsPossible(first, array)) {
+          return false;
+        }
+      }
+      return true;
     }
 
Index: /branches/2913_MatlabScriptProblemInstanceProvider/HeuristicLab.Problems.Instances.DataAnalysis/3.3/Regression/Matlab/Api/Types/MLTimeseries.cs
===================================================================
--- /branches/2913_MatlabScriptProblemInstanceProvider/HeuristicLab.Problems.Instances.DataAnalysis/3.3/Regression/Matlab/Api/Types/MLTimeseries.cs	(revision 15925)
+++ /branches/2913_MatlabScriptProblemInstanceProvider/HeuristicLab.Problems.Instances.DataAnalysis/3.3/Regression/Matlab/Api/Types/MLTimeseries.cs	(revision 15926)
@@ -3,4 +3,5 @@
 using System.Linq;
 using System.Text;
+using System.Threading;
 using System.Threading.Tasks;
 
@@ -24,5 +25,5 @@
     /// </summary>
     /// <param name="timeseries"></param>
-    public MLTimeseries(IEnumerable<MLTimeseries> timeseries) : this() {
+    public MLTimeseries(IEnumerable<MLTimeseries> timeseries, CancellationToken token) : this() {
       var dataHeaders = new List<string>();
       var times = new SortedSet<double>(); // The time values have to be unique and sorted.
@@ -64,4 +65,7 @@
 
           foreach (var v in vs) {
+            if (token.IsCancellationRequested) {
+              return;
+            }
             values[idx++] = v;
           }
Index: /branches/2913_MatlabScriptProblemInstanceProvider/HeuristicLab.Problems.Instances.DataAnalysis/3.3/Regression/Matlab/Api/Types/MLVariableInfo.cs
===================================================================
--- /branches/2913_MatlabScriptProblemInstanceProvider/HeuristicLab.Problems.Instances.DataAnalysis/3.3/Regression/Matlab/Api/Types/MLVariableInfo.cs	(revision 15926)
+++ /branches/2913_MatlabScriptProblemInstanceProvider/HeuristicLab.Problems.Instances.DataAnalysis/3.3/Regression/Matlab/Api/Types/MLVariableInfo.cs	(revision 15926)
@@ -0,0 +1,26 @@
+﻿using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+using System.Threading.Tasks;
+
+namespace HeuristicLab.Problems.Instances.DataAnalysis.Regression.Matlab.Api.Types {
+  public class MLVariableInfo {
+
+    public string VarName { get; set; }
+
+    public MLDatatype Datatype { get; set; }
+
+    public double Row { get; set; }
+
+    public double Column { get; set; }
+
+    public MLVariableInfo() {
+      Datatype = MLDatatype.Undefinded;
+    }
+
+    public override string ToString() {
+      return string.Format("{0}, {1}, {2}x{3}", VarName, Datatype, Row, Column);
+    }
+  }
+}
Index: /branches/2913_MatlabScriptProblemInstanceProvider/HeuristicLab.Problems.Instances.DataAnalysis/3.3/Regression/Matlab/RegressionMatlabInstanceProvider.cs
===================================================================
--- /branches/2913_MatlabScriptProblemInstanceProvider/HeuristicLab.Problems.Instances.DataAnalysis/3.3/Regression/Matlab/RegressionMatlabInstanceProvider.cs	(revision 15925)
+++ /branches/2913_MatlabScriptProblemInstanceProvider/HeuristicLab.Problems.Instances.DataAnalysis/3.3/Regression/Matlab/RegressionMatlabInstanceProvider.cs	(revision 15926)
@@ -67,5 +67,5 @@
 
 
-    public IRegressionProblemData ImportData(string path, RegressionMatlabImportType type, IEnumerable<KeyValuePair<string, MLDatatype>> variableNames) {
+    public IRegressionProblemData ImportData(string path, RegressionMatlabImportType type, IEnumerable<MLVariableInfo> variableNames) {
       var dataset = type.Values;
       var targetVar = type.TargetVariable;
