My EA making deals every tick. I want it as the tester model: Open Prices Only

 

Hello,


I have my (MT4) EA ready. I have tested it with Tester Model: Open Prices Only. And it works well.

When I try it on Demo. It works as Every Tick. It goes into many trades at the same bar and trade. 

How can I make it works as 1 trade per deal. Lets say 1 trade per Candle. I tried many and many codes but none works for me.


Thanks

Damati

The Fundamentals of Testing in MetaTrader 5
The Fundamentals of Testing in MetaTrader 5
  • www.mql5.com
The idea of ​​automated trading is appealing by the fact that the trading robot can work non-stop for 24 hours a day, seven days a week. The robot does not get tired, doubtful or scared, it's is totally free from any psychological problems. It is sufficient enough to clearly formalize the trading rules and implement them in the algorithms, and...
 
DAMATI: Lets say 1 trade per Candle.

For a new bar test, Bars is unreliable (a refresh/reconnect can change number of bars on chart,) volume is unreliable (miss ticks,) Price is unreliable (duplicate prices and The == operand. - MQL4 programming forum.) Always use time.

I disagree with making a new bar function, because it can only be called once per tick. A variable can be tested multiple times.
          New candle - MQL4 programming forum

 
William Roeder:

For a new bar test, Bars is unreliable (a refresh/reconnect can change number of bars on chart,) volume is unreliable (miss ticks,) Price is unreliable (duplicate prices and The == operand. - MQL4 programming forum.) Always use time.

I disagree with making a new bar function, because it can only be called once per tick. A variable can be tested multiple times.
          New candle - MQL4 programming forum


Thanks

I got it solved