SimpleSAR_EA

Strategies are published here.

Moderator: admin

SimpleSAR_EA

Postby Apprentice » Tue Nov 12, 2019 5:35 am

EURUSD m1 (11-12-2019 0942).png

Based on MT4 version.
viewtopic.php?f=38&p=129440
SimpleSAR_EA.lua
(57.6 KiB) Downloaded 141 times
User avatar
Apprentice
FXCodeBase: Confirmed User
 
Posts: 25400
Joined: Thu Dec 31, 2009 11:59 am
Location: Zagreb, Croatia

Re: SimpleSAR_EA

Postby fabio70 » Mon May 11, 2020 10:28 am

Dear Apprentice,

Could you please add to this SimpleSAR strategy a START/STOP time for trading with manditory closing time.
Thanks
fabio70
 
Posts: 14
Joined: Mon Jan 15, 2018 9:56 am

Re: SimpleSAR_EA

Postby fabio70 » Tue May 12, 2020 7:55 am

Sorry, I forgot to ask if you could also add a limit function.
Thank you
fabio70
 
Posts: 14
Joined: Mon Jan 15, 2018 9:56 am

Re: SimpleSAR_EA

Postby Apprentice » Tue May 12, 2020 11:22 am

Your request is added to the development list.
Development reference 1276.
User avatar
Apprentice
FXCodeBase: Confirmed User
 
Posts: 25400
Joined: Thu Dec 31, 2009 11:59 am
Location: Zagreb, Croatia

Re: SimpleSAR_EA

Postby papynou34 » Wed May 13, 2020 4:04 am

Hello Apprentice,
Thanks for your work.
I noticed that the Période information is missing on panel of running stratégy.
It seems, you have to add :
strategy.parameters:setFlag("timeframe", core.FLAG_PERIODS);

Thanks
Attachments
samplesar.PNG
papynou34
FXCodeBase: Initiate
 
Posts: 109
Joined: Fri Mar 27, 2015 6:52 pm

Re: SimpleSAR_EA

Postby papynou34 » Wed May 13, 2020 7:49 am

Hello Apprentice,
It seems there is a bug in the stratégy with mandatory closing time. I did a backtest and
-If mandatory closing time to False : in this case the strategy just runs one day.
-if mandatory closing is set to True, i Have the following error message :

C:/Program Files (x86)/Candleworks/FXTS2.test/Strategies/Custom/SimpleSAR_EA.lua:-1: stack overflow
papynou34
FXCodeBase: Initiate
 
Posts: 109
Joined: Fri Mar 27, 2015 6:52 pm

Re: SimpleSAR_EA

Postby fabio70 » Wed May 13, 2020 7:52 am

Hi Apprentice,
thank you for your work, but I must say that the strategy does not work anymore, even with all the new functions disabled.
The previous version in the backtest give me back a huge number of orders, now it only opens very few orders.
Is there any parameter that should be set differently?
And I have no more the previous version since the new one substituted it.
Thank you
fabio70
 
Posts: 14
Joined: Mon Jan 15, 2018 9:56 am

Re: SimpleSAR_EA

Postby Apprentice » Wed May 13, 2020 8:52 am

Your request is added to the development list.
Development reference 1287.
User avatar
Apprentice
FXCodeBase: Confirmed User
 
Posts: 25400
Joined: Thu Dec 31, 2009 11:59 am
Location: Zagreb, Croatia

Re: SimpleSAR_EA

Postby Apprentice » Thu May 14, 2020 4:24 am

SimpleSAR_EA.lua
(63.75 KiB) Downloaded 14 times

Try this version.
User avatar
Apprentice
FXCodeBase: Confirmed User
 
Posts: 25400
Joined: Thu Dec 31, 2009 11:59 am
Location: Zagreb, Croatia

Re: SimpleSAR_EA

Postby fabio70 » Thu May 14, 2020 7:39 am

OK, now the strategy works when the new functions are disabled, but when mandatory closing is set to on (I tried two different times) the strategy does not open orders nor in backtest nor in optimization.
fabio70
 
Posts: 14
Joined: Mon Jan 15, 2018 9:56 am

Next

Return to Custom Strategies

Who is online

Users browsing this forum: wuhuilin11 and 12 guests