Optimal Timeframe for EA Optimization

Hi everyone,

For the MetaTrader builders and expert advisor experts out there, what timeframe do you generally recommend for optimizing a good EA?

I’ve heard that using very old data (e.g., 10+ years) might not be ideal for today’s market conditions. On the other hand, relying solely on very recent data (e.g., the past year) might lead to strategies that fail long-term tests or are overfit to recent market behavior.

What are your thoughts on finding the right balance? What timeframes have you found to be most effective in creating robust and reliable Set files for EAs?

Thanks in advance for your insights!

1 Like

Hi MoDa :slight_smile:

I am testing my Expert Advisor with DukasCopy data from 2003 until today. This has several advantages: 1. a lot of crashes and crises have happened during this time. This gives me an impression of how this EA has ‘survived’ during these times. 2. as you said, overfitting can occur with very short time spans.
3. the long time span also allows me to see whether the market has actually changed and if so, I can see how my EA has performed.

As I want my EAs to be profitable in the long term, I avoid short tests. These are not relevant for me.

The short tests are very often a favourite tool of scammers to show how great their EAs are doing! :wink:

Hi @MoDaTrade,

Most EA in the market only fit to use for certain condition.
For example, during sideways or trending market. When market is change its style, EA mostly will fail. Unless, you have an EA that can detect this changes.

Using AI also won’t be helpful. AI is pattern seeking. If the AI is being rigid, over-fitting will be the result.

My advice is try to backtest the EA, look its trading style. When the strategy is averaging, you need bit capital to cover the volatile years, for example GBPUSD in 2022, USDCHF around 2014.

Running an EA, you have to able to analyze market fundamental. Don’t know it, you just like turn on a car, without driver. It will hit something soon or later.

If you have capability to develop an EA, detecting market phase is the priority.
My self own EA, implement minimum 4 strategies to deal with market. You need to detect market on strong timeframe to define which strategy to use. At least you have to look H4 timeframe. Risk can be reduced a lot from here.

You don’t need to back-test the history too long. For example, USDJPY’s patterns bellow 2009 were different compare to 2015. So, using EA 2020, certainly won’t have good result bellow 2010.

Using automated trading system, doesn’t mean you can be free. I’m using EA since 2011, I have to adjust my algorithm mostly every 3-6 months.