Course Name: Backtesting Trading Strategies, Section No: 5, Unit No: 10, Unit type: Notebook
for the computation of the strategy returns, you shift the signal column only by one moove. Do you assume that you execute the trade at the same time of the computation of the signal?
Hi Khalil,
While calculating returns, we are simply calculating the price change of the asset and then multiplying it by the signal value.
For instance, we are holding a long position wherever the signal is '1'. So to compute the returns that we have generated by going long, we should multiply the percentage change in price by the signal.
Hope this helps!
Thanks
Rushda