Implementing an algorithmic "Buy Into The Close" trading strategy on Large Cap Equity CFDs - $AMZN
'Buying into the close', as the name implies is the practice of placing last minute market orders in the direction of price momentum just before the close of the trading day.
I will be starting with $AMZN CFDs using HotForex's historical market data. On their platform, Equity CFD markets open at 16:30 and close at 22:00.
In order to determine & measure market momentum, I will be using a short EMA, and opening trades based on the relationship between market price and the EMA at 22:00. I will also be automatically closing the trades a few hours after market open.
My Buy and BuyIntoClose functions:
My Trade Close function:
Backtesting the algorithm on a H1 chart:
Backtest report:
Download the full report here.