- Timestamp:
- 09/24/12 09:44:08 (12 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/sources/HeuristicLab.Problems.Instances.DataAnalysis/3.3/Clustering/CSV/ClusteringCSVInstanceProvider.cs
r8601 r8685 130 130 public override void ExportData(IClusteringProblemData instance, string path) { 131 131 var strBuilder = new StringBuilder(); 132 133 foreach (var variable in instance. InputVariables) {134 strBuilder.Append(variable + CultureInfo.CurrentCulture.TextInfo.ListSeparator);132 var colSep = CultureInfo.CurrentCulture.TextInfo.ListSeparator; 133 foreach (var variable in instance.Dataset.VariableNames) { 134 strBuilder.Append(variable.Replace(colSep, String.Empty) + colSep); 135 135 } 136 strBuilder.Remove(strBuilder.Length - CultureInfo.CurrentCulture.TextInfo.ListSeparator.Length, CultureInfo.CurrentCulture.TextInfo.ListSeparator.Length);136 strBuilder.Remove(strBuilder.Length - colSep.Length, colSep.Length); 137 137 strBuilder.AppendLine(); 138 138 … … 141 141 for (int i = 0; i < dataset.Rows; i++) { 142 142 for (int j = 0; j < dataset.Columns; j++) { 143 if (j > 0) strBuilder.Append( CultureInfo.CurrentCulture.TextInfo.ListSeparator);143 if (j > 0) strBuilder.Append(colSep); 144 144 strBuilder.Append(dataset.GetValue(i, j)); 145 145 }
Note: See TracChangeset
for help on using the changeset viewer.