Changeset 10308
- Timestamp:
- 01/08/14 15:16:03 (11 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/DataPreprocessing/HeuristicLab.DataPreprocessing/3.3/Implementations/PreprocessingDataManipulation.cs
r10256 r10308 3 3 using System.Linq; 4 4 using HeuristicLab.Data; 5 using System.Collections; 5 6 6 7 namespace HeuristicLab.DataPreprocessing { … … 142 143 143 144 private void reOrderToIndices<T>(string variableName, IList<Tuple<int, int>> indices) { 145 146 List<T> originalData = new List<T>(preprocessingData.GetValues<T>(variableName)); 147 144 148 // process all columns equally 145 149 foreach (Tuple<int, int> index in indices) { … … 147 151 int replaceIndex = index.Item2; 148 152 149 T tmp = preprocessingData.GetCell<T>(variableName, originalIndex); 150 T replaceValue = preprocessingData.GetCell<T>(variableName, replaceIndex); 151 153 T replaceValue = originalData.ElementAt<T>(replaceIndex); 152 154 preprocessingData.SetCell<T>(variableName, originalIndex, replaceValue); 153 preprocessingData.SetCell<T>(variableName, replaceIndex, tmp);154 155 } 155 156 }
Note: See TracChangeset
for help on using the changeset viewer.