-
Notifications
You must be signed in to change notification settings - Fork 79
Backtest Not run with SMA #32
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
Comments
This command fixe the issues inside the main FXbot directory |
Perfect! |
Sorry to reopen this issue but the command do not work, I don't know way after I run that command was working but when I stop the bot and run again I get the same error again. AttributeError: 'Index' object has no attribute 'tz_localize' EUR_USD sma, bollinger_bands, contrarian, momentum, ml_classification, ml_regression, 2022-04-19 2022-04-19 1.0811 M1 7 14 |
Ok, it looks that the issue only appears when the start and the end date are the same. |
this backtest setup work sma, bollinger_bands, contrarian, momentum, ml_classification, ml_regression, 2022-04-19 2022-04-20 1.0811 M1 7 18 |
I think I found the issue only works with granularity M1 or S30 |
Interesting. Ill take a look |
Traceback (most recent call last):
File "main.py", line 214, in
trader = SMABacktest(instrument, start, end, smas, smal, granularity, trading_cost)
File "/root/FXBot/backtesting/SMABacktest.py", line 25, in init
super().init(
File "/root/FXBot/backtesting/Backtester.py", line 27, in init
self._data = self.acquire_data()
File "/root/FXBot/backtesting/Backtester.py", line 41, in acquire_data
df = oanda.get_history(
File "/root/FXBot/env/lib/python3.8/site-packages/tpqoa-0.0.55-py3.8.egg/tpqoa/tpqoa.py", line 241, in get_history
AttributeError: 'Index' object has no attribute 'tz_localize'
The text was updated successfully, but these errors were encountered: