Free cookie consent management tool by TermsFeed Policy Generator

Ignore:
Timestamp:
06/10/09 19:05:34 (15 years ago)
Author:
gkronber
Message:

Implemented base classes for variable impact analysis and implemented specific operators for GP. #644 (Variable impact of CEDMA models should be calculated and stored in the result DB)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/sources/HeuristicLab.Modeling/3.2/Model.cs

    r2034 r2041  
    120120    }
    121121
    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];
    124129      else return 0.0;
    125130    }
     
    133138    #endregion
    134139
    135     private Dictionary<string, double> variableImpacts = new Dictionary<string, double>();
    136     public void SetVariableImpact(string variableName, double impact) {
    137       variableImpacts[variableName] = impact;
     140    private Dictionary<string, double> variableQualityImpacts = new Dictionary<string, double>();
     141    public void SetVariableQualityImpact(string variableName, double impact) {
     142      variableQualityImpacts[variableName] = impact;
    138143    }
    139144
    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;
    142156    }
    143157  }
Note: See TracChangeset for help on using the changeset viewer.