Changeset 7405 for branches/RegressionBenchmarks/HeuristicLab.Problems.DataAnalysis.Benchmarks/3.4/RegressionBenchmarks/Other/BreimanOne.cs
- Timestamp:
- 01/24/12 16:23:47 (12 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/RegressionBenchmarks/HeuristicLab.Problems.DataAnalysis.Benchmarks/3.4/RegressionBenchmarks/Other/BreimanOne.cs
r7127 r7405 65 65 List<List<double>> dataList = new List<List<double>>(); 66 66 List<int> values = new List<int>() { -1, 1 }; 67 dataList.Add( RegressionBenchmark.GenerateUniformIntegerDistribution(values, testPartition.End));67 dataList.Add(BreimanOne.GenerateUniformIntegerDistribution(values, testPartition.End)); 68 68 values.Add(0); 69 69 for (int i = 0; i < inputVariables.Count - 1; i++) { 70 dataList.Add( RegressionBenchmark.GenerateUniformIntegerDistribution(values, testPartition.End));70 dataList.Add(BreimanOne.GenerateUniformIntegerDistribution(values, testPartition.End)); 71 71 } 72 72 73 73 return dataList; 74 74 } 75 76 public static List<double> GenerateUniformIntegerDistribution(List<int> classes, int amount) { 77 List<double> values = new List<double>(); 78 for (int i = 0; i < amount; i++) { 79 values.Add(classes[rand.Next(0, classes.Count)]); 80 } 81 return values; 82 } 75 83 } 76 84 }
Note: See TracChangeset
for help on using the changeset viewer.