Changeset 2041 for trunk/sources/HeuristicLab.Modeling/3.2/Model.cs
- Timestamp:
- 06/10/09 19:05:34 (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/sources/HeuristicLab.Modeling/3.2/Model.cs
r2034 r2041 120 120 } 121 121 122 public double GetVariableImpact(string variableName) { 123 if (variableImpacts.ContainsKey(variableName)) return variableImpacts[variableName]; 122 public double GetVariableQualityImpact(string variableName) { 123 if (variableQualityImpacts.ContainsKey(variableName)) return variableQualityImpacts[variableName]; 124 else return 1.0; 125 } 126 127 public double GetVariableEvaluationImpact(string variableName) { 128 if (variableEvaluationImpacts.ContainsKey(variableName)) return variableEvaluationImpacts[variableName]; 124 129 else return 0.0; 125 130 } … … 133 138 #endregion 134 139 135 private Dictionary<string, double> variable Impacts = new Dictionary<string, double>();136 public void SetVariable Impact(string variableName, double impact) {137 variable Impacts[variableName] = impact;140 private Dictionary<string, double> variableQualityImpacts = new Dictionary<string, double>(); 141 public void SetVariableQualityImpact(string variableName, double impact) { 142 variableQualityImpacts[variableName] = impact; 138 143 } 139 144 140 public void SetVariableImpact(int variableIndex, double impact) { 141 variableImpacts[dataset.GetVariableName(variableIndex)] = impact; 145 public void SetVariableQualityImpact(int variableIndex, double impact) { 146 variableQualityImpacts[dataset.GetVariableName(variableIndex)] = impact; 147 } 148 149 private Dictionary<string, double> variableEvaluationImpacts = new Dictionary<string, double>(); 150 public void SetVariableEvaluationImpact(string variableName, double impact) { 151 variableEvaluationImpacts[variableName] = impact; 152 } 153 154 public void SetVariableEvaluationImpact(int variableIndex, double impact) { 155 variableEvaluationImpacts[dataset.GetVariableName(variableIndex)] = impact; 142 156 } 143 157 }
Note: See TracChangeset
for help on using the changeset viewer.