mirror of
https://github.com/Akkudoktor-EOS/EOS.git
synced 2025-04-19 08:55:15 +00:00
median
This commit is contained in:
parent
3121490a23
commit
aec2171570
@ -139,6 +139,10 @@ class ElecPriceAkkudoktor(ElecPriceProvider):
|
|||||||
).fit()
|
).fit()
|
||||||
return model.forecast(prediction_hours)
|
return model.forecast(prediction_hours)
|
||||||
|
|
||||||
|
def _predict_median(self, history: np.ndarray, prediction_hours: int) -> np.ndarray:
|
||||||
|
clean_history = self._cap_outliers(history)
|
||||||
|
return np.full(prediction_hours, np.median(clean_history))
|
||||||
|
|
||||||
def _update_data(self, force_update: Optional[bool] = False) -> None:
|
def _update_data(self, force_update: Optional[bool] = False) -> None:
|
||||||
"""Update forecast data in the ElecPriceDataRecord format.
|
"""Update forecast data in the ElecPriceDataRecord format.
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user