Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

multi-time frame data not working #77

Open
ziyedbe opened this issue Feb 7, 2023 · 0 comments
Open

multi-time frame data not working #77

ziyedbe opened this issue Feb 7, 2023 · 0 comments

Comments

@ziyedbe
Copy link

ziyedbe commented Feb 7, 2023

Describe the bug
I m getting the following error when i try to use multi time frame data

AutoTraderBot assigned to trade BTC-USD with virtual broker using EMA Crossover.

Trading...

  0%|                                                                                               | 0/2678400 [00:00<?, ?it/s]Traceback (most recent call last):
  File "PATH/Desktop\work\shared\personal\autotrader-demo\runfile.py", line 9, in <module>
    at.run()
  File "PATH/AppData\Local\Programs\Python\Python39\lib\site-packages\autotrader\autotrader.py", line 1142, in run  
    self._main()
  File "PATH/AppData\Local\Programs\Python\Python39\lib\site-packages\autotrader\autotrader.py", line 1660, in _main    self._trade_update_loop()
  File "PATH/AppData\Local\Programs\Python\Python39\lib\site-packages\autotrader\autotrader.py", line 2134, in _trade_update_loop
    bot._update(timestamp=timestamp)
  File "PATH/AppData\Local\Programs\Python\Python39\lib\site-packages\autotrader\autobot.py", line 306, in _update  
    self._update_virtual_broker(current_bars)
  File "PATH/AppData\Local\Programs\Python\Python39\lib\site-packages\autotrader\autobot.py", line 663, in _update_virtual_broker
    brokers = self._instrument_to_broker[product]
KeyError: '1h'
 13%|██████████                                                                 | 360000.0/2678400 [00:00<00:01, 2014412.79it/s] 

To Reproduce
Steps to reproduce the behavior:
Run the MTF_ema_crossover strategy

Version of AutoTrader being used
Autotrader : 0.12.0
Python : 3.9.0

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant