Small updates while reviewing
This commit is contained in:
parent
f1c5a4d065
commit
ac2fb08aea
@ -270,8 +270,7 @@ def refresh_backtest_ohlcv_data(exchange: Exchange, pairs: List[str], timeframes
|
|||||||
|
|
||||||
if erase:
|
if erase:
|
||||||
if data_handler.ohlcv_purge(pair, timeframe, candle_type=candle_type):
|
if data_handler.ohlcv_purge(pair, timeframe, candle_type=candle_type):
|
||||||
logger.info(
|
logger.info(f'Deleting existing data for pair {pair}, interval {timeframe}.')
|
||||||
f'Deleting existing data for pair {pair}, interval {timeframe}.')
|
|
||||||
|
|
||||||
logger.info(f'Downloading pair {pair}, interval {timeframe}.')
|
logger.info(f'Downloading pair {pair}, interval {timeframe}.')
|
||||||
process = f'{idx}/{len(pairs)}'
|
process = f'{idx}/{len(pairs)}'
|
||||||
@ -290,8 +289,7 @@ def refresh_backtest_ohlcv_data(exchange: Exchange, pairs: List[str], timeframes
|
|||||||
# TODO: this could be in most parts to the above.
|
# TODO: this could be in most parts to the above.
|
||||||
if erase:
|
if erase:
|
||||||
if data_handler.ohlcv_purge(pair, timeframe, candle_type=candle_type):
|
if data_handler.ohlcv_purge(pair, timeframe, candle_type=candle_type):
|
||||||
logger.info(
|
logger.info(f'Deleting existing data for pair {pair}, interval {timeframe}.')
|
||||||
f'Deleting existing data for pair {pair}, interval {timeframe}.')
|
|
||||||
_download_pair_history(pair=pair, process=process,
|
_download_pair_history(pair=pair, process=process,
|
||||||
datadir=datadir, exchange=exchange,
|
datadir=datadir, exchange=exchange,
|
||||||
timerange=timerange, data_handler=data_handler,
|
timerange=timerange, data_handler=data_handler,
|
||||||
|
@ -57,6 +57,7 @@ def informative(timeframe: str, asset: str = '',
|
|||||||
|
|
||||||
def decorator(fn: PopulateIndicators):
|
def decorator(fn: PopulateIndicators):
|
||||||
informative_pairs = getattr(fn, '_ft_informative', [])
|
informative_pairs = getattr(fn, '_ft_informative', [])
|
||||||
|
# TODO-lev: Add candle_type to InformativeData
|
||||||
informative_pairs.append(InformativeData(_asset, _timeframe, _fmt, _ffill))
|
informative_pairs.append(InformativeData(_asset, _timeframe, _fmt, _ffill))
|
||||||
setattr(fn, '_ft_informative', informative_pairs)
|
setattr(fn, '_ft_informative', informative_pairs)
|
||||||
return fn
|
return fn
|
||||||
|
@ -530,7 +530,7 @@ class IStrategy(ABC, HyperStrategyMixin):
|
|||||||
dataframe = self.analyze_ticker(dataframe, metadata)
|
dataframe = self.analyze_ticker(dataframe, metadata)
|
||||||
self._last_candle_seen_per_pair[pair] = dataframe.iloc[-1]['date']
|
self._last_candle_seen_per_pair[pair] = dataframe.iloc[-1]['date']
|
||||||
if self.dp:
|
if self.dp:
|
||||||
self.dp._set_cached_df(pair, self.timeframe, dataframe, CandleType.SPOT)
|
self.dp._set_cached_df(pair, self.timeframe, dataframe, CandleType.SPOT_)
|
||||||
# TODO-lev: CandleType should be set conditionally
|
# TODO-lev: CandleType should be set conditionally
|
||||||
else:
|
else:
|
||||||
logger.debug("Skipping TA Analysis for already analyzed candle")
|
logger.debug("Skipping TA Analysis for already analyzed candle")
|
||||||
|
Loading…
Reference in New Issue
Block a user