- Timestamp:
- 08/10/08 11:37:05 (16 years ago)
- Location:
- trunk/sources/HeuristicLab.StructureIdentification/Evaluation
- Files:
-
- 11 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/sources/HeuristicLab.StructureIdentification/Evaluation/AccuracyEvaluator.cs
r479 r480 65 65 double est = GetEstimatedValue(sample); 66 66 double origClass = GetOriginalValue(sample); 67 SetOriginalValue(sample, est); 67 68 double estClass = double.NaN; 68 69 // if estimation is lower than the smallest threshold value -> estimated class is the lower class -
trunk/sources/HeuristicLab.StructureIdentification/Evaluation/ClassificationMeanSquaredErrorEvaluator.cs
r479 r480 60 60 double estimated = GetEstimatedValue(sample); 61 61 double original = GetOriginalValue(sample); 62 SetOriginalValue(sample, estimated); 62 63 if(!double.IsNaN(original) && !double.IsInfinity(original)) { 63 64 double error = estimated - original; -
trunk/sources/HeuristicLab.StructureIdentification/Evaluation/CoefficientOfDeterminationEvaluator.cs
r479 r480 49 49 double estimated = GetEstimatedValue(sample); 50 50 double original = GetOriginalValue(sample); 51 SetOriginalValue(sample, estimated); 51 52 if(!double.IsNaN(original) && !double.IsInfinity(original)) { 52 53 double error = estimated - original; -
trunk/sources/HeuristicLab.StructureIdentification/Evaluation/EarlyStoppingMeanSquaredErrorEvaluator.cs
r479 r480 58 58 double estimated = GetEstimatedValue(sample); 59 59 double original = GetOriginalValue(sample); 60 SetOriginalValue(sample, estimated); 60 61 if(!double.IsNaN(original) && !double.IsInfinity(original)) { 61 62 double error = estimated - original; -
trunk/sources/HeuristicLab.StructureIdentification/Evaluation/GPEvaluatorBase.cs
r479 r480 114 114 public abstract double Evaluate(int start, int end); 115 115 116 public void SetOriginalValue(int sample, double value) { 117 if(useEstimatedValues) { 118 dataset.SetValue(sample, targetVariable, value); 119 } 120 } 121 116 122 public double GetOriginalValue(int sample) { 117 if(useEstimatedValues) 118 return backupValues[sample - trainingStart]; 119 else 120 return dataset.GetValue(sample, targetVariable); 123 return dataset.GetValue(sample, targetVariable); 121 124 } 122 125 … … 131 134 estimated = estimatedValueMin; 132 135 } 133 134 if(useEstimatedValues) {135 dataset.SetValue(sample, targetVariable, estimated);136 }137 138 136 return estimated; 139 137 } -
trunk/sources/HeuristicLab.StructureIdentification/Evaluation/MCCEvaluator.cs
r479 r480 62 62 double est = GetEstimatedValue(sample); 63 63 double orig = GetOriginalValue(sample); 64 SetOriginalValue(sample, est); 64 65 estimated[sample - start] = est; 65 66 original[sample - start] = orig; -
trunk/sources/HeuristicLab.StructureIdentification/Evaluation/MeanAbsolutePercentageErrorEvaluator.cs
r479 r480 48 48 double estimated = GetEstimatedValue(sample); 49 49 double original = GetOriginalValue(sample); 50 SetOriginalValue(sample, estimated); 50 51 if(!double.IsNaN(original) && !double.IsInfinity(original)) { 51 52 double percent_error = Math.Abs((estimated - original) / original); -
trunk/sources/HeuristicLab.StructureIdentification/Evaluation/MeanSquaredErrorEvaluator.cs
r479 r480 48 48 double original = GetOriginalValue(sample); 49 49 double estimated = GetEstimatedValue(sample); 50 SetOriginalValue(sample, estimated); 50 51 if(!double.IsNaN(original) && !double.IsInfinity(original)) { 51 52 double error = estimated - original; -
trunk/sources/HeuristicLab.StructureIdentification/Evaluation/SimpleEvaluator.cs
r479 r480 55 55 for(int sample = start; sample < end; sample++) { 56 56 ItemList row = new ItemList(); 57 row.Add(new DoubleData(GetEstimatedValue(sample))); 58 row.Add(new DoubleData(GetOriginalValue(sample))); 57 double estimated = GetEstimatedValue(sample); 58 double original = GetOriginalValue(sample); 59 SetOriginalValue(sample, estimated); 60 row.Add(new DoubleData(estimated)); 61 row.Add(new DoubleData(original)); 59 62 values.Add(row); 60 63 } -
trunk/sources/HeuristicLab.StructureIdentification/Evaluation/TheilInequalityCoefficientEvaluator.cs
r479 r480 59 59 double estimatedChange = GetEstimatedValue(sample) - prevValue; 60 60 double originalChange = GetOriginalValue(sample) - prevValue; 61 SetOriginalValue(sample, estimatedChange+prevValue); 61 62 if(!double.IsNaN(originalChange) && !double.IsInfinity(originalChange)) { 62 63 double error = estimatedChange - originalChange; -
trunk/sources/HeuristicLab.StructureIdentification/Evaluation/VarianceAccountedForEvaluator.cs
r479 r480 60 60 double estimated = GetEstimatedValue(sample); 61 61 double original = GetOriginalValue(sample); 62 SetOriginalValue(sample, estimated); 62 63 if(!double.IsNaN(original) && !double.IsInfinity(original)) { 63 64 errors[sample - start] = original - estimated;
Note: See TracChangeset
for help on using the changeset viewer.