Download MetaTrader 5

strategy testing debugging

To add comments, please log in or register
Code Base will help you in mastering your theoretical skills. Come and learn!
michelino
216
michelino 2013.06.30 16:15 

hello everybody

I'm trying to backtest and forward test some advisors I've downloaded, unfortunately some of them don't trade, they take some minutes to run the test and then I've zero trades in the report.

it there any debugger other then print()? or do you know which are the main causes for this kind of problem? 

Alain Verleyen
Moderator
30702
Alain Verleyen 2013.06.30 16:50  
michelino:

hello everybody

I'm trying to backtest and forward test some advisors I've downloaded, unfortunately some of them don't trade, they take some minutes to run the test and then I've zero trades in the report.

it there any debugger other then print()? or do you know which are the main causes for this kind of problem? 

Hi, do you have some info printed on the Journal tab ?
michelino
216
michelino 2013.06.30 19:04  
angevoyageur:
Hi, do you have some info printed on the Journal tab ?

hi Alain, 

I'm glad you answered I had this issue on asctrend advisor.

in the journal tab I have many lines like this:

GQ 0 18:49:44 Core 1 2012.12.17 07:00:00   Open sell  failed. Return code=10030. Code description: invalid fill

do you need the full log?

thanks 

Alain Verleyen
Moderator
30702
Alain Verleyen 2013.06.30 21:07  
michelino:

hi Alain, 

I'm glad you answered I had this issue on asctrend advisor.

in the journal tab I have many lines like this:

GQ 0 18:49:44 Core 1 2012.12.17 07:00:00   Open sell  failed. Return code=10030. Code description: invalid fill

do you need the full log?

thanks 

Hello Michele,

No need for the full log, you have the change 1 line of code :

    trade.SetTypeFilling(ORDER_FILLING_RETURN);                         // Order filling mode, the mode allowed by the server should be used

by

    trade.SetTypeFilling(ORDER_FILLING_FOK);                            // Order filling mode, the mode allowed by the server should be used
or eventually by ORDER_FILLING_IOC. Asctrend EA was my first program in mql5 and contains some limitations.
Documentation on MQL5: Standard Constants, Enumerations and Structures / Trade Constants / Order Properties
Documentation on MQL5: Standard Constants, Enumerations and Structures / Trade Constants / Order Properties
  • www.mql5.com
Standard Constants, Enumerations and Structures / Trade Constants / Order Properties - Documentation on MQL5
michelino
216
michelino 2013.07.01 17:34  
angevoyageur:

Hello Michele,

No need for the full log, you have the change 1 line of code :

by

or eventually by ORDER_FILLING_IOC. Asctrend EA was my first program in mql5 and contains some limitations.

I've tried in both ways with same results.

I've recompiled and restarted mt5 getting the same results.

I've tried with ASCtrendND and ASCtrendEA 

could be because of some input parameters? 

graziani
1953
graziani 2013.07.01 19:27  
try another broker.
michelino
216
michelino 2013.07.01 20:43  
graziani:
try another broker.

I've a demo account.

btw simpler EA like movingAverages one are working on backtesting and fwtesting

Documentation on MQL5: Standard Constants, Enumerations and Structures / Environment State / Account Properties
Documentation on MQL5: Standard Constants, Enumerations and Structures / Environment State / Account Properties
  • www.mql5.com
Standard Constants, Enumerations and Structures / Environment State / Account Properties - Documentation on MQL5
Alain Verleyen
Moderator
30702
Alain Verleyen 2013.07.01 20:59  
michelino:

I've a demo account.

btw simpler EA like movingAverages one are working on backtesting and fwtesting

You can see in the presentation of AsctrendND EA that :

Known limitations:

Don't work with ECN Broker (Market execution type).
So this is maybe your problem (see your PM).
michelino
216
michelino 2013.07.02 16:37  
angevoyageur:

You can see in the presentation of AsctrendND EA that :

So this is maybe your problem (see your PM).

it works if I change the initial capital. maybe is a matter of some risk parameter. it's better if I study the code

thanks for your help

To add comments, please log in or register