Changeset 15856 for branches/2906_Transformations/HeuristicLab.Problems.DataAnalysis/3.4/Implementation/Regression
- Timestamp:
- 03/23/18 14:10:15 (7 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/2906_Transformations/HeuristicLab.Problems.DataAnalysis/3.4/Implementation/Regression/RegressionProblemData.cs
r15847 r15856 181 181 } 182 182 183 public override IDataAnalysisProblemData Transform() { 184 var transformedProblemData = (IRegressionProblemData)base.Transform(); 185 var targetVariable = GetTransformedTragetVariable(TargetVariable, Transformations); 186 transformedProblemData.TargetVariable = targetVariable; 187 return transformedProblemData; 188 } 189 183 190 public override IDataAnalysisProblemData InverseTransform() { 184 191 var transformedProblemData = (IRegressionProblemData)base.InverseTransform(); … … 186 193 transformedProblemData.TargetVariable = targetVariable; 187 194 return transformedProblemData; 195 } 196 197 public static string GetTransformedTragetVariable(string originalTarget, IEnumerable<IDataAnalysisTransformation> transformations) { 198 var transformedTarget = originalTarget; 199 foreach (var transformation in transformations) { 200 if (transformation.OriginalVariable == transformedTarget) 201 transformedTarget = transformation.TransformedVariable; 202 } 203 return transformedTarget; 188 204 } 189 205
Note: See TracChangeset
for help on using the changeset viewer.