Though moving averages are an important tool there are always two questions when plotting them:
- what period should i use ?
- on what timeframe shall i use them?
below i tried to make a statistical backtesting test to answer the above questions.
The backtest uses two variables:
T, for timeframe, and it is a multiple of 1h. So for example 24h is in fact a day. I must mention that the backtester engine automatically converts 24h to a day, or 8h to one 8h candle.
P: this is the period for which the MA's will be drawn.
The condition is if Close > MA then buy, if Close < MA then short. Signal is given on close of the candle and price is Close.
Spread is 3 pips. Backtesting period is 2000 - Jan 2011.
margin is 1:1 (spot trading)
after the backtest (it took 1 h and a half) i got the following results which i imported in excel for charting convenience.
% profit of the system
drawdown of the system (max system loss)
Sharpe Ratio with a risk free ratio of 5%
periods of MA's
Timeframes of MA's
So...
According to tests the optimum combinations converge to a period of 250 on a timeframe of 50-60 hours. In fact a MA of 250 ploted on a 2 day timeframe. is the most optimum combination. Or at least was form 2000 till Jan 2011
But will this system work? This is why i used sharpe ratio with a risk free of 5%/year. The score on sharpe ratio on the best combinations converges towards 0.5. So it means it STATISTICALY produces half of the risk free ratio (0.5*5%), meaning 2.5%. If 2.5% per year is ok with you, then this system is good to go.
But considering this is on a 10 year period, many long term bonds offer much better return, so it is not really worth your money.
In the end we could use a higher margin, lets say 2:1. In this case reward should be 5% annualized, but DrawDown should also be double. In 1:1, DD is between 10 and 20%. Doubling, we get a max DD of 20-40%. So a 5% return for a max 40% DD. Not really worth it.
Meaning trading with ONLY 1 MA , no matter what period , no matter what TF .. is not worth it.
happy trading.
Radu Ciofu, PBfx.eu
- what period should i use ?
- on what timeframe shall i use them?
below i tried to make a statistical backtesting test to answer the above questions.
The backtest uses two variables:
T, for timeframe, and it is a multiple of 1h. So for example 24h is in fact a day. I must mention that the backtester engine automatically converts 24h to a day, or 8h to one 8h candle.
P: this is the period for which the MA's will be drawn.
The condition is if Close > MA then buy, if Close < MA then short. Signal is given on close of the candle and price is Close.
Spread is 3 pips. Backtesting period is 2000 - Jan 2011.
margin is 1:1 (spot trading)
after the backtest (it took 1 h and a half) i got the following results which i imported in excel for charting convenience.
% profit of the system
drawdown of the system (max system loss)
Sharpe Ratio with a risk free ratio of 5%
periods of MA's
Timeframes of MA's
So...
According to tests the optimum combinations converge to a period of 250 on a timeframe of 50-60 hours. In fact a MA of 250 ploted on a 2 day timeframe. is the most optimum combination. Or at least was form 2000 till Jan 2011
But will this system work? This is why i used sharpe ratio with a risk free of 5%/year. The score on sharpe ratio on the best combinations converges towards 0.5. So it means it STATISTICALY produces half of the risk free ratio (0.5*5%), meaning 2.5%. If 2.5% per year is ok with you, then this system is good to go.
But considering this is on a 10 year period, many long term bonds offer much better return, so it is not really worth your money.
In the end we could use a higher margin, lets say 2:1. In this case reward should be 5% annualized, but DrawDown should also be double. In 1:1, DD is between 10 and 20%. Doubling, we get a max DD of 20-40%. So a 5% return for a max 40% DD. Not really worth it.
Meaning trading with ONLY 1 MA , no matter what period , no matter what TF .. is not worth it.
happy trading.
Radu Ciofu, PBfx.eu
