Beispiel #1
0
    def number_of_values_to_forecast_test(self):
        """Test the valid calculation of values to forecast."""
        data = [[1.5, 152.0],[2.5, 172.8],[3.5, 195.07200000000003],[4.5, 218.30528000000004]]
        ts   = TimeSeries.from_twodim_list(data)
        ts.normalize("second")

        bfm  = BaseForecastingMethod()

        bfm.forecast_until(100)
        bfm._calculate_values_to_forecast(ts)

        assert bfm.get_parameter("valuesToForecast") == 96
Beispiel #2
0
    def number_of_values_to_forecast_test(self):
        """Test the valid calculation of values to forecast."""
        data = [[1.5, 152.0], [2.5, 172.8], [3.5, 195.07200000000003],
                [4.5, 218.30528000000004]]
        ts = TimeSeries.from_twodim_list(data)
        ts.normalize("second")

        bfm = BaseForecastingMethod()

        bfm.forecast_until(100)
        bfm._calculate_values_to_forecast(ts)

        assert bfm.get_parameter("valuesToForecast") == 96