Add comment to explain why we use the non-trimmed DF

This commit is contained in:
Matthias 2022-09-06 06:52:50 +02:00
parent 9f5642fd97
commit 4dec19de9f

View File

@ -421,8 +421,9 @@ class Hyperopt:
preprocessed = self.backtesting.strategy.advise_all_indicators(data)
# Trim startup period from analyzed dataframe to get correct dates for output.
processed = trim_dataframes(preprocessed, self.timerange, self.backtesting.required_startup)
self.min_date, self.max_date = get_timerange(processed)
trimmed = trim_dataframes(preprocessed, self.timerange, self.backtesting.required_startup)
self.min_date, self.max_date = get_timerange(trimmed)
# Real trimming will happen as part of backtesting.
return preprocessed
def prepare_hyperopt_data(self) -> None: