- Timestamp:
- 06/19/16 19:56:11 (9 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/sources/HeuristicLab.Algorithms.DataAnalysis/3.4/RandomForest/RandomForestModel.cs
r12509 r13921 45 45 } 46 46 47 public IEnumerable<string> VariablesUsedForPrediction { 48 get { return originalTrainingData.AllowedInputVariables; } 49 } 50 51 public string TargetVariable { 52 get { 53 var regressionProblemData = originalTrainingData as IRegressionProblemData; 54 var classificationProblemData = originalTrainingData as IClassificationProblemData; 55 if (classificationProblemData != null) 56 return classificationProblemData.TargetVariable; 57 if (regressionProblemData != null) 58 return regressionProblemData.TargetVariable; 59 throw new InvalidOperationException("Getting the target variable requires either a regression or a classification problem data."); 60 } 61 } 62 47 63 // instead of storing the data of the model itself 48 64 // we instead only store data necessary to recalculate the same model lazily on demand
Note: See TracChangeset
for help on using the changeset viewer.