Realtime debug - Printable Version +- Gekko Forum (https://forum.gekko.wizb.it) +-- Forum: Gekko (https://forum.gekko.wizb.it/forum-13.html) +--- Forum: General Discussion (https://forum.gekko.wizb.it/forum-14.html) +--- Thread: Realtime debug (/thread-58020.html) |
Realtime debug - aixbr - 10-08-2019 Hi, I have a simple strategy that is : strat.init = function() { this.addTulipIndicator('ema10','ema',{ optInTimePeriod:10 }); this.addTulipIndicator('ema21','ema',{ optInTimePeriod:21 }); } strat.check = function(candle) { const ema10 = this.tulipIndicators.ema10.result.result; const ema21 = this.tulipIndicators.ema21.result.result; if(ema10>ema21){ console.log("buy); } else { console.log("sell"); } that is work good in a backtest enviroment. I already changed the line below in config.js : config['I understand that Gekko only automates MY OWN trading strategies'] = true and i am running with this command line : node gekko --config config.js but nothing is printed in console when the condition goes true or not. How can i put it to run in realtime mode !? RE: Realtime debug - Hallonstedt - 10-09-2019 (10-08-2019, 10:04 PM)aixbr Wrote: if(ema10>ema21){ You seem to be missing a ' " ' after buy Code: console.log("buy); RE: Realtime debug - aixbr - 10-09-2019 for sure... a forgot the quotes. thanks. it is more strang... did not do any error. Look likes that do not read this part of the code. That is my feeling. but i continue to not have sucess in realmode. Do not log anything. Have any config extra to run in realmode ?! Can u send me a single code and the config.js file that can just log some when the ema(7) cross ema(21), for exemple, please !? and that it can really run in realmode. Please ! |