Changeset 7965
- Timestamp:
- 06/05/12 10:50:54 (12 years ago)
- Location:
- trunk/sources/HeuristicLab.Problems.Instances.DataAnalysis/3.3
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/sources/HeuristicLab.Problems.Instances.DataAnalysis/3.3/Classification/ClassificationInstanceProvider.cs
r7851 r7965 36 36 37 37 Dataset dataset = new Dataset(csvFileParser.VariableNames, csvFileParser.Values); 38 string targetVar = csvFileParser.VariableNames. Last();39 IEnumerable<string> allowedInputVars = csvFileParser.VariableNames.Where(x => !x.Equals(targetVar));38 string targetVar = csvFileParser.VariableNames.Where(x => dataset.DoubleVariables.Contains(x)).Last(); 39 IEnumerable<string> allowedInputVars = dataset.DoubleVariables.Where(x => !x.Equals(targetVar)); 40 40 41 41 ClassificationProblemData claData = new ClassificationProblemData(dataset, allowedInputVars, targetVar); -
trunk/sources/HeuristicLab.Problems.Instances.DataAnalysis/3.3/Classification/ResourceClassificationInstanceProvider.cs
r7851 r7965 70 70 71 71 Dataset dataset = new Dataset(csvFileParser.VariableNames, csvFileParser.Values); 72 string targetVar = csvFileParser.VariableNames. Last();73 IEnumerable<string> allowedInputVars = csvFileParser.VariableNames.Where(x => !x.Equals(targetVar));72 string targetVar = csvFileParser.VariableNames.Where(x => dataset.DoubleVariables.Contains(x)).Last(); 73 IEnumerable<string> allowedInputVars = dataset.DoubleVariables.Where(x => !x.Equals(targetVar)); 74 74 75 75 ClassificationProblemData claData = new ClassificationProblemData(dataset, allowedInputVars, targetVar); -
trunk/sources/HeuristicLab.Problems.Instances.DataAnalysis/3.3/Regression/RegressionInstanceProvider.cs
r7860 r7965 36 36 37 37 Dataset dataset = new Dataset(csvFileParser.VariableNames, csvFileParser.Values); 38 string targetVar = csvFileParser.VariableNames. Last();38 string targetVar = csvFileParser.VariableNames.Where(x => dataset.DoubleVariables.Contains(x)).Last(); 39 39 40 IEnumerable<string> allowedInputVars = csvFileParser.VariableNames.Where(x => !x.Equals(targetVar));40 IEnumerable<string> allowedInputVars = dataset.DoubleVariables.Where(x => !x.Equals(targetVar)); 41 41 42 42 IRegressionProblemData regData = new RegressionProblemData(dataset, allowedInputVars, targetVar); -
trunk/sources/HeuristicLab.Problems.Instances.DataAnalysis/3.3/Regression/ResourceRegressionInstanceProvider.cs
r7851 r7965 70 70 71 71 Dataset dataset = new Dataset(csvFileParser.VariableNames, csvFileParser.Values); 72 string targetVar = csvFileParser.VariableNames. Last();73 IEnumerable<string> allowedInputVars = csvFileParser.VariableNames.Where(x => !x.Equals(targetVar));72 string targetVar = csvFileParser.VariableNames.Where(x => dataset.DoubleVariables.Contains(x)).Last(); 73 IEnumerable<string> allowedInputVars = dataset.DoubleVariables.Where(x => !x.Equals(targetVar)); 74 74 75 75 IRegressionProblemData regData = new RegressionProblemData(dataset, allowedInputVars, targetVar);
Note: See TracChangeset
for help on using the changeset viewer.