Free cookie consent management tool by TermsFeed Policy Generator

Ignore:
Timestamp:
07/04/19 13:00:24 (5 years ago)
Author:
mkommend
Message:

#2955: Merged r16241, r16243, r16244, r16763 into stable.

Location:
stable
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • stable

  • stable/HeuristicLab.Problems.DataAnalysis

  • stable/HeuristicLab.Problems.DataAnalysis/3.4

  • stable/HeuristicLab.Problems.DataAnalysis/3.4/Implementation/TimeSeriesPrognosis/TimeSeriesPrognosisProblemData.cs

    r15584 r17054  
    16201620      OnChanged();
    16211621    }
    1622 
    1623     protected override bool IsProblemDataCompatible(IDataAnalysisProblemData problemData, out string errorMessage) {
    1624       if (problemData == null) throw new ArgumentNullException("problemData", "The provided problemData is null.");
    1625       ITimeSeriesPrognosisProblemData timeseriesProblemData = problemData as ITimeSeriesPrognosisProblemData;
    1626       if (timeseriesProblemData == null)
    1627         throw new ArgumentException("The problem data is not a time-series problem data. Instead a " + problemData.GetType().GetPrettyName() + " was provided.", "problemData");
    1628 
    1629       var returnValue = base.IsProblemDataCompatible(problemData, out errorMessage);
    1630       //check targetVariable
    1631       if (problemData.InputVariables.All(var => var.Value != TargetVariable)) {
    1632         errorMessage = string.Format("The target variable {0} is not present in the new problem data.", TargetVariable)
    1633                        + Environment.NewLine + errorMessage;
    1634         return false;
    1635       }
    1636       return returnValue;
    1637     }
    1638 
    1639     public override void AdjustProblemDataProperties(IDataAnalysisProblemData problemData) {
    1640       TimeSeriesPrognosisProblemData timeSeriesProblemData = problemData as TimeSeriesPrognosisProblemData;
    1641       if (timeSeriesProblemData == null)
    1642         throw new ArgumentException("The problem data is not a timeseries problem data. Instead a " + problemData.GetType().GetPrettyName() + " was provided.", "problemData");
    1643 
    1644       var trainingDataStart = TrainingIndices.First();
    1645 
    1646       base.AdjustProblemDataProperties(problemData);
    1647 
    1648       TestPartition.Start = trainingDataStart;
    1649 
    1650       TrainingHorizon = timeSeriesProblemData.TrainingHorizon;
    1651       TestHorizon = timeSeriesProblemData.TestHorizon;
    1652     }
    1653 
    16541622  }
    16551623}
Note: See TracChangeset for help on using the changeset viewer.