How the strategy works
| Rule | How it works |
|---|---|
| Long entry | The 20 EMA closes above the 50 EMA on a confirmed bar. |
| Short entry | The 20 EMA closes below the 50 EMA on a confirmed bar. |
| Reversal | An opposite cross closes the current position before opening the new one. The strategy is never long and short at once and never adds to a position. |
| Stop | 2 x ATR(14) from the entry price. |
| Target | 3 x ATR(14) from the entry price. Stop and target are set when the trade opens. |
| Exit | Whichever comes first: stop, target or an opposite cross. |
| Position size | 100% of the simulated account per trade, one position at a time. |
There is no trend, volume or session filter, so the strategy takes every cross, including those in sideways markets.
When signals fire
- Signals are confirmed on bar close. A cross that appears mid-bar and disappears before the close does not open a trade.
- Backtests fill orders at the close of the signal bar. Live market orders fill after the close, at the next available price, so live results can differ.
Backtest assumptions
| Setting | Default | Note |
|---|---|---|
| Initial capital | 10,000 | In the quote currency of the market tested |
| Size per trade | 100% of equity | One position at a time |
| Pyramiding | 1 | One open entry per direction |
| Commission | 0.1% per order | Binance spot taker fee at the base tier |
| Slippage | 1 tick | A minimal estimate for market orders |
| Fill timing | Bar close | Orders fill at the close of the signal bar |
You can change all of these in the backtest settings.
Settings
| Input | Default | Range |
|---|---|---|
| Fast EMA length | 20 | 1 to 400 |
| Slow EMA length | 50 | 1 to 400 |
| ATR length | 14 | 1 to 100 |
| ATR stop multiplier | 2 | 0.1 to 10 |
| ATR target multiplier | 3 | 0.1 to 20 |
| Equity per trade (%) | 100 | 1 to 100 |
Backtest results
Backtest results for this strategy are coming soon. They will show the market, timeframe, date range and assumptions used.
Past performance does not guarantee future results.
Risks and limitations
- Short trades need margin or futures. On a spot account you can only run the long side.
- Crossovers lag price, and sideways markets produce repeated false signals.
- Bar-close fills in backtests are more favourable than live market orders.
- This strategy is a starting point, not financial advice. Test it on paper before trading live.
How to use it in Altrady
- Sign in to your Altrady account to run strategies. Sign in
- Adjust the settings and backtest assumptions to your market.
- Run a backtest and review the results.
- Paper trade, then connect it to a Signal Bot when you are ready.
Frequently asked questions
It is a trend-following approach that uses two exponential moving averages of different lengths. When the faster average crosses above the slower one, recent prices have overtaken the longer trend and the strategy goes long; when it crosses below, it goes short. This one uses a 20 and a 50.
ATR measures how far the market has been moving per bar, so a stop set as a multiple of it adapts to conditions. The same 2 x ATR stop sits wider in a volatile market and tighter in a quiet one, where a fixed percentage would be too tight in the first case and too loose in the second.
Only the long side. Short entries mean selling a coin you do not hold, which needs a margin or futures account. On spot you can trade the long signals and ignore the short ones, which changes the results.
Yes. Fast EMA length defaults to 20 and Slow EMA length to 50, and both accept 1 to 400. The ATR length and the stop and target multipliers are adjustable too. Test a change rather than assuming a shorter pair signals better.
No. Signals are read only on confirmed bars, so a cross that forms mid-bar and disappears before the close never opens a trade, and a signal on a closed bar is not revised afterwards.
Backtesting runs in the Altrady terminal and needs an account. Sign in, open the strategy, set the market and timeframe you want to test, adjust the assumptions listed on this page, then run the backtest and review the results.