[SHARE] Simple RSI BULL/BEAR strategy
(04-24-2018, 02:35 AM)gt3 Wrote: Hey guys, firstly, I've been following this thread since inception and have had 5 instances of Gekko running very nicely for about 2 months. I started using the RSI_BULL_BEAR strategy when it was first posted and subsequently changed to the improved RSI_BULL_BEAR_ADX strategy.

My existing instances have been producing a nice return lately and I am wanting to spin up another one. As a result I downloaded to the latest version of gekko_tools and copied over the gekko-extra-indicators as per the instructions. I've also created the json file RSI_BULL_BEAR_ADX.json (placed it next to the existing toml version in gekko/config/strategies) both by using the code example posted by Kris191 earlier in this thread and also by using an online converter. However, I'm still getting the error when attempting a backtest:

2018-04-24 02:29:26 (INFO): Setting up Gekko in backtest mode
2018-04-24 02:29:26 (INFO):
2018-04-24 02:29:26 (INFO): Setting up:
2018-04-24 02:29:26 (INFO): Trading Advisor
2018-04-24 02:29:26 (INFO): Calculate trading advice
2018-04-24 02:29:26 (INFO): Using the strategy: RSI_BULL_BEAR_ADX
/home/admin/gekko/strategies/RSI_BULL_BEAR_ADX.js:39
this.addIndicator('maSlow', 'SMA', this.settings.SMA.long );
                                                ^

TypeError: Cannot read property 'SMA' of undefined
   at Base.init (/home/admin/gekko/strategies/RSI_BULL_BEAR_ADX.js:39:52)
   at Base.bound [as init] (/home/admin/gekko/node_modules/lodash/dist/lodash.js:729:21)
   at new Base (/home/admin/gekko/plugins/tradingAdvisor/baseTradingMethod.js:87:8)
   at Actor.setupTradingMethod (/home/admin/gekko/plugins/tradingAdvisor/tradingAdvisor.js:62:17)
   at Actor.bound [as setupTradingMethod] (/home/admin/gekko/node_modules/lodash/dist/lodash.js:729:21)
   at new Actor (/home/admin/gekko/plugins/tradingAdvisor/tradingAdvisor.js:23:8)
   at load (/home/admin/gekko/core/pluginUtil.js:95:22)
   at /home/admin/gekko/node_modules/async/dist/async.js:1156:9
   at replenish (/home/admin/gekko/node_modules/async/dist/async.js:1030:17)
   at iterateeCallback (/home/admin/gekko/node_modules/async/dist/async.js:1015:17)

This a brand new install with the latest version of Gekko, gekko_tools, gekko-extra-indicators (copied to both gekko/strategies and gekko/strategies/indicators), tulind. I'm using version 1.0.2 of talib.

I've spent hours trying to debug this Sad Sorry to be a pain but really hoping someone can help out! Thank you for all your work so far @tommiehansen and for everyone else contributions

You're using an outdated TOML-file for some reason. It basically is saying that

[SMA]
long = xxxxxx

Does not exist.
Latest version of RBB ADX does not use tulip or talib.
  Reply


Messages In This Thread
Werkkrew Stoploss - by susitronix - 02-02-2018, 09:39 PM
Removed post - by susitronix - 02-03-2018, 06:49 PM
@Gryphon Confirmation - by mvangoor - 03-22-2019, 11:59 PM
for 3 months - by ankasem - 02-18-2018, 05:30 PM
RE: [SHARE] Simple RSI BULL/BEAR strategy - by tommiehansen - 04-24-2018, 08:17 AM

Forum Jump:


Users browsing this thread: