Free cookie consent management tool by TermsFeed Policy Generator

Ignore:
Timestamp:
10/19/18 13:27:06 (6 years ago)
Author:
mkommend
Message:

#2955: Added IsProblemDataCompatible and IsDatasetCompatible to all DataAnalysisModels.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/HeuristicLab.Problems.DataAnalysis.Symbolic.Classification/3.4/SymbolicClassificationModel.cs

    r15583 r16243  
    7474    }
    7575
     76    public virtual bool IsProblemDataCompatible(IClassificationProblemData problemData, out string errorMessage) {
     77      return ClassificationModel.IsProblemDataCompatible(this, problemData, out errorMessage);
     78    }
     79
     80    public override bool IsProblemDataCompatible(IDataAnalysisProblemData problemData, out string errorMessage) {
     81      if (problemData == null) throw new ArgumentNullException("problemData", "The provided problemData is null.");
     82      var classificationProblemData = problemData as IClassificationProblemData;
     83      if (classificationProblemData == null)
     84        throw new ArgumentException("The problem data is not a regression problem data. Instead a " + problemData.GetType().GetPrettyName() + " was provided.", "problemData");
     85      return IsProblemDataCompatible(classificationProblemData, out errorMessage);
     86    }
     87
    7688    #region events
    7789    public event EventHandler TargetVariableChanged;
Note: See TracChangeset for help on using the changeset viewer.