Strategy Tester: Period Setting

 

Hi All

I have written an EA which operates on the timeframe defined manually in the Expert Inputs tab, rather than the timeframe of the attached chart.

When I run the EA in the strategy tester i get significantly different results when the Period setting (in the Strategy Tester) is changed, even when the timeframe in the Expert Settings Inputs remains the same. Each test is executed using the Every Tick model.

Can someone provide some insight into what is happening? Hopefully I have explained the situation clearly.

Many thanks in advance for any help.

David

 
colombodave:

Hi All

I have written an EA which operates on the timeframe defined manually in the Expert Inputs tab, rather than the timeframe of the attached chart.

When I run the EA in the strategy tester i get significantly different results when the Period setting (in the Strategy Tester) is changed, even when the timeframe in the Expert Settings Inputs remains the same. Each test is executed using the Every Tick model.

Can someone provide some insight into what is happening? Hopefully I have explained the situation clearly.

Many thanks in advance for any help.

David

somewhere in the code you used a PERIOD_CURRENT instead of the default input period. (or 0, if that 0 means the "current timeframe" for the function parameter)

 
Code2219 or probably 2319:

somewhere in the code you used a PERIOD_CURRENT instead of the default input period. (or 0, if that 0 means the "current timeframe" for the function parameter)

Thank you for your quick reply.

I have gone through every line of the code with a fine tooth comb, and there are no occurrences of that, so I conclude that it must be something else.

Further to the information in my first post, I have looked through the reports generated by the strategy tester and they are operating identically for the first ~75 trades, at which point their behaviour diverges. I don't know if this sheds further light on what may be happening..?

 

Could it be:

If you don't have actual tick data the Strategy tester simulates ticks using high/low/open/close etc therefore this simulation of ticks may be different between difference time frames causing different results??

 
Did you download all history ?
 

@Marco vd Heijden I have downloaded 1-minute data for the entire period being modelled.

@iRick do you think the strategy tester is utilising the 1 minute data differently for the different period settings? Or do you think it's using different data entirely? For example using 1-minute data for a period setting of 5min then using 1hr data for a period setting of 4hrs

Thank you for your replies

Reason: