After building algorithmic trading strategies, as we did in the previous chapter, the first step is to backtest them over a given duration of time for a given strategy configuration.
Backtesting is a method of evaluating the performance of a trading strategy by virtually executing it over past data and analyzing its risk and return metrics. Real money is not used here. Typical backtesting metrics include Profit and Loss (P&L), maximum drawdown, count of total trades, winning trades, losing trades, long trades and short trades, average profit per winning and losing trade, and more. Until these metrics meet the necessary requirements, the entire process should be repeated with incremental changes being made to strategy parameters and/or strategy implementation.
If a strategy performs well on past data, it is likely to perform well on live data...